How do I convert a text file that I'm transferring between Mac OS or Mac OS X and Windows?
Mac OS and Mac OS X use different characters from Windows to indicate the end of each line in a plain text or Rich Text Format (RTF) file. Windows places both a line feed and a carriage return character at the end of each line, but Mac OS uses only a carriage return character, and Mac OS X sometimes uses carriage returns and sometimes uses line feeds (but usually not both). Some Windows applications need to see line feed characters at the ends of lines, and may treat Mac-format files as giant single lines with an odd graphic character inserted where ends of lines should be. Some Mac OS and Mac OS X applications won't recognize the line feeds added in Windows and will also display a box-like character at the start or end of each line after the first.
Note: This does not apply to files created using applications such as Word or WordPerfect; these applications save files in their own format which is designed to be cross-platform.
The simplest way to transfer the contents of a plain text or RTF file is to copy and paste the contents from the file into an email message.
When you transfer a text file between Mac OS or Mac OS X and Windows with an FTP or SFTP client, the program can convert the end-of-line characters. Often they will do this automatically, but sometimes you have to change some settings. For information about changing these settings, see the instructions below:
Transmit
When using Transmit to move a text file between Windows and
Mac OS or Mac OS X, be sure the file is transferred in
ASCII mode. This will ensure that the document is
transformed into a text format appropriate for the host. Normally,
Transmit will automatically choose the mode in which to transfer a
file; to force it to transfer files as text, from the File
menu, select ASCII Mode.
Fetch
When using Fetch to move a text file between Mac OS or Mac
OS X and Windows, be sure that the file is transferred while Fetch is
in Text mode. This will ensure that the document is transformed into
a text format appropriate for the host. In Fetch 4, once you've made a
connection to the Windows computer, next to "Mode:", select
Text. In Fetch 3, once you've made a connection to the
Windows computer, click the Text radio button.
MacSFTP
When using MacSFTP to move a text file between Mac OS or Mac OS X and
Windows, be sure that you have set the program to convert text files.
To do this, from the MacSFTP menu (Mac OS X) or Edit
menu (Mac OS 9), select Preferences... . In the
preferences window, click the File-Transfer tab, then check
the box next to Translate text files linefeeds. Click the
Save button, and then MacSFTP will convert transferred text
files.
Hummingbird FTP
When using Hummingbird to move a text file between Windows and Mac OS
or Mac OS X, make sure the file is being transferred in
ASCII format. In Hummingbird, the default format is Auto
Transfer. To change the format to ensure that the file is being
transferred in ASCII, from the Options menu, choose ASCII
Transfer.
SSH Secure File Transfer
When using SSH Secure File Transfer to move a text file
between Windows and Mac OS or Mac OS X, make sure the file is being
transferred in ASCII format. In SSH, the default format is
Auto Transfer. To change the format to ensure that the file is being
transferred in ASCII, go to the Edit menu, then select
Settings. On the left side of the window, click the plus sign
next to Global Settings to expand it. In the list that opens,
click the plus sign next to File Transfer to expand
it. Select Mode, then, on the right, select ASCII.
Command line FTP
When using a command line FTP program to move a text file between operating systems, be sure the file is transferred in ASCII format. This will ensure that the document is transformed into a text format appropriate for the host. At the FTP prompt, before beginning a transfer, enter the command:
asciiAlso see:
- When using FTP, why might programs and files fail to transfer properly?
- With FTP from DOS, how do I transfer files?
- How do I convert between Unix and Windows text files?
- In Mac OS and Mac OS X, what should I do if Fetch isn't decoding downloaded BinHex, MacBinary, or StuffIt files?
- What are some common FTP commands?
- Helpful hints for using FTP
- How do I convert between Unix and Mac OS or Mac OS X text files?
- At IU, what SSH/SFTP clients are supported and where can I get them?
Last modified on May 15, 2005.






