ASCII vs Binary FTP Transfer Mode
When uploading files via FTP, you may need to choose between ASCII and Binary transfer modes.
When to Use Each Mode
- Binary mode: Use for all non-text files including images (jpg, png, gif), compressed files (zip, tar.gz), PDFs, videos, audio, executables, and any file format that is not plain text. Binary mode transfers files byte-for-byte without any conversion.
- ASCII mode: Use for plain text files including HTML, CSS, PHP, Perl scripts, JavaScript, and configuration files. ASCII mode converts line endings between operating systems (Windows uses CRLF, Linux uses LF).
Recommended: Use Auto Mode
Most modern FTP clients (including FileZilla) default to Auto mode, which automatically detects the file type and uses the correct transfer mode. We recommend leaving it on Auto. In FileZilla, this is set under Transfer > Transfer type > Auto.
Uploading a binary file in ASCII mode (or vice versa) can corrupt the file. If an image appears broken or a script does not work after uploading, re-upload it using the correct transfer mode.
