Home » Tech Tips » Mac » 5 Ways to Create a New Blank Text Document File in Mac?

5 Ways to Create a New Blank Text Document File in Mac?

Text files on your Mac help storing simple information and jotting down a quick note. These text files are created, saved, and edited without styling or formatting. In short, these are plain text files with .txt file extension. Good thing about these plain text documents is that they are supported by all types of text-editing software for reading and editing the data. Did you ever wonder or struggle with creating a blank text document file in Mac? In this article, we will explore various options available for that purpose to make your life easier.

Creating Blank Text File in MacBook

In Windows PC, you can simply right-click and create blank text file anywhere in desktop or File Explorer. Unfortunately, MacBook doesn’t have an option of creating .txt file with just one click like Windows. If you have just switched to MacBook, it may be confusing for you to create a blank text document file. Below are some of the ways to create a text file on Mac and you can follow the one you like.

1. Using Run AppleScript in Automator 

Most Mac users do not aware there is an app called Automator which comes default with macOS. As the name indicates, Automator simplifies daily tasks by creating custom shortcuts and avoiding performing repetitive tasks manually. In short, you can create workflows to automate tasks and here we will use the app for creating a blank text file with a click.

  • Open Finder app and go to Applications folder.
  • Find Automator and double-click to open the app.
Launch Automator App in Mac
Launch Automator App in Mac
  • You will be prompted to choose a type for your document. In this case, we want to create an application. So, select “Application” option from the list and click “Choose” button.
Choose Application in Automator App
Choose Application in Automator App
  • In the “Variables” search bar, type “Run AppleScript” to filter that option from the list.
Filter Run AppleScript Variable
Filter Run AppleScript Variable
  • Drag and drop “Run AppleScript” option into the workflow panel.
  • You will see some default text in the box. Simply delete all the text written in the panel and copy paste the below command.
tell application "Finder" to make new file at (the target of the front window) as alias
Paste the Script
Paste the Script
  • This command will allow Finder app to create a blank text file. If required, you can click “Run” option showing on top right corner of the app to test the command. When ready, go to the “File” menu and click on “Save”.
  • In the dialog box that pops up, type the desired name of your application. For example, we name it as “My Text File” as shown in the screenshot below. Here, one thing to consider is, select “Applications” for both “Where” and “File Format”. This will save the file in your Applications folder. If you want to change the location, click on the small arrow against “Where” option to browse and choose different location on your Mac.   
Name Automator Application
Name Automator Application
  • Now, open Finder and go to the Applications folder. You will find “My Text File” Automator app and double-click on it.
Automator App for Creating Blank Text File
Automator App for Creating Blank Text File
Provide Access Control for App
Provide Access Control for App
  • This will create a new blank text file with the name as “untitled”.
  • You will get a new blank text file every time when you double-click that app. You can copy or move the Automator app file to desktop or documents folder to create a text file in that location.

Note: You can also import this workflow in Shortcuts app to use from there.

2. Using New Text File in Automator App

As the above-mentioned steps are extensive and lengthy, you can also use an alternate and simple method.

  • After creating an “Application” in Automator app, type, “New Text file” in the “Variables” search box.
Use New Text File Script in Automator
Use New Text File Script in Automator
  • You will get that item on the list, simply drag and drop that “New Text File” to the workflow Panel.
  • As you can see, the new text file will be created with the name as “Untitled.txt” in “Desktop” with UTF-8 encoding. If required, you can change any of these parameters. For example, enter the output name of your new as “To do list.txt” in the “Save as” text box.
Name the Save as Text File Name
Name the Save as Text File Name
  • Now, press, “Command + S” or go to “File > Save” menu to save your application file. Let us save the app with the same name as “To do list” in Applications folder.
Name the Automator App Name
Name the Automator App Name
  • Go to “Finder > Applications” and  you will find the Automator app with the name “To do list”. Whenever you double-click that application file, it will generate a blank text file with the name as “To do list.txt” in the desktop.
App Created in Applications Folder
App Created in Applications Folder

3. Using Automator Quick Action

Instead of creating application with Automator, you can also create Quick Action. The difference is that Quick Action items will appear in the “Finder > Services” menu so that you can use it anywhere in Finder app instead of a particular location in the above methods. Follow the below steps to create a blank text file in Mac using Automator Quick Action.

  • Open Automator app and create a “Quick Action” workflow instead of “Application”.
Open Quick Action in Automator App
Open Quick Action in Automator App
  • Add “Run AppleScript” variable and paste in same command as explained in method 1 above.
tell application "Finder" to make new file at (the target of the front window) as alias
  • Press “Command + S” to save your Quick Action with any name you like. Lat us give a name as “Create Text File” for our Quick Action.
Save Quick Action from Automator in Mac
Save Quick Action from Automator in Mac
  • Now, go to Finder app and navigate to “Finder > Services” menu.
  • You will see additional menu item is added and select “Create Text File” option.
Create Text File Services in Finder Services
Create Text File Services in Finder Services
  • It will great a blank text file with the name as “untitled” in your current location.

From there, now you can open and write anything you want to, in that plain text file using TextEdit app.

4. Using Terminal to Create Blank Text File in Mac

Mac has a system command to create a blank text file using Terminal app.

  • Press “Command + Space” to open Spotlight Search.
  • Type “Terminal” in the search box and open Terminal app.
Open Terminal from Spotlight Search in Mac
Open Terminal from Spotlight Search in Mac
  • When you are in Terminal app, type the following command to move the prompt to desktop folder.
cd desktop
  • After that type the following command and press enter.
touch [name of the file].txt
Create Text File from Terminal in Mac
Create Text File from Terminal in Mac
  • In the given command, make sure to replace [name of the file] with the name you want for your text file (for example – mylist.txt).
  • This will create a blank text file with the name as “mylist.txt” in your desktop folder.

Note: If you want to create a text file in a particular folder in Finder app, you can open the Terminal app from that folder instead of using CD command to change directory at prompt. For this go to “Apple menu > System Preferences > Keyboard > Shortcuts > Services” and enable “New Terminal at Folder” option.

Enable New Terminal at Folder Finder Service
Enable New Terminal at Folder Finder Service

With this option enabled, select any folder and go to “Finder > Services” menu. You will find a new menu item “New Terminal at Folder” added, click on it to launch Terminal app from that folder.

Open New Terminal from a Folder
Open New Terminal from a Folder

Now, you can use same touch command for creating a blank text file from the folder you have launched Terminal app.

5. Using TextEdit to Create a Text File in Mac

TextEdit is the default word processing program in MacBook which allows users to create, edit, and format text. This is one of the simplest ways to create a text file in Mac. However, TextEdit app by default uses Rich Text Format (.rtf) which is not a plain text. You can use the following steps to convert RTF to TXT format or always open plain TXT file in TextEdit app.

  • Use Spotlight Search to find and open TextEdit app. Alternatively, go to “Finder > Applications” and open TextEdit app from there.
  • When the app opens, select “New Document” from the dialog box.
Open New TextEdit Document in Mac
Open New TextEdit Document in Mac
  • The app will show a rich text format editor like below with all formatting options.
TextEdit Rich Text Editor Interface
TextEdit Rich Text Editor Interface
  • Before start typing your text content, go to “Format” menu and select “Make Plain Text” option. Alternatively, you can use “Shift + Command + T” shortcut keys to toggle RTF and plain text editors.
Make Plain Text Option in TextEdit App
Make Plain Text Option in TextEdit App
  • The plain text editor in TextEdit app will look like below. Now, type your content and save the file in UTF-8 plain text format with .txt file extension.
TextEdit Plain Text Editor
TextEdit Plain Text Editor

If you always to open new document in TextEdit with plain text format, then go to “TextEdit > Preferences” menu in the app. Select “Plain text” option under “New Document” tab. You can also add TextEdit app in Dock by dragging the app from “Finder > Applications” folder to quickly launch a new plain document.

Always Open Plain Text Editor in TextEdit App
Always Open Plain Text Editor in TextEdit App

Note: Avoid converting existing RTF file to text file in TextEdit using “Format > Make Plain Text” option. This will remove all styles like bold, colors, etc. and delete the images. You will also see a warning message when you are trying to convert the file. Clicking “OK” in the warning will permanently delete the styles and rich media content and you will not be able to get them back using “Format > Make Rich Text” menu.

Avoid Converting RTF to TXT in TextEdit
Avoid Converting RTF to TXT in TextEdit

Frequently Asked Questions for Creating a Blank Text File in Mac

Here is a summary and FAQ on creating a new text document in Mac.

1. What is the easiest method to create a new blank text document in Mac?

Using Automator script is the easiest method for creating a text document in Mac. You can either use an Application or use Quick Action workflow for this purpose.

2. Why my Automator app is not creating a text file?

Make sure to select the correct script and type in the correct command in Automator app. Use “Application” File Format when saving your file and check in the correct output location which you have selected in “Where” field when saving the Automator application.

3. What is the difference between Quick Action and Application in Automator?

Application will create an app in the specified folder while Quick Action will create a menu item in “Finder > Services”.

4. Can I add app created with Automator in Dock for quick use?

Yes, you can simply drag and drop the app in your Dock from “Finder > Applications” folder. This will help to quickly create a text file in the specified output folder.

5. Can I use Terminal for creating a text file in a specified folder?

Yes, you can enable “New Terminal at Folder” service and use that option from “Finder > Services” menu from any folder.

Leave a Comment

Your email address will not be published. Required fields are marked *