Shell
IFS
Internal Field Separator used for shell word splitting.
Ubuntu
Debian
Arch
Fedora
CentOS
SUSE
Alpine
macOS
FreeBSD
Verified: 2026-05-12
Syntax
$echo "$IFS"
Examples
$oldIFS=$IFS; IFS=','; set -- $line; IFS=$oldIFS
$while IFS= read -r line; do ...; done < file.txt
Typical use cases
?
Standard usage
IFS --help
Note
Controls how the shell splits strings into fields.
Export