Movatterモバイル変換


[0]ホーム

URL:


NO_COLOR

Last updated: 2026-02-09

An increasing number of command-line software programs output text withANSI colorescape codes by default.While some developers and users obviously prefer seeing these colors,some users don’t.Unfortunately, every new piece of software seems to have adifferent wayof disabling colored text output and some software has no way at all.

Accepting the futility of trying to reverse this trend, an informal standardwas proposed in 2017:

Command-line software which adds ANSI color to its output by default shouldcheck for aNO_COLOR environment variable that, when present and not an emptystring (regardless of its value), prevents the addition of ANSI color.

By adopting this standard, users that prefer to have plain, non-colored textoutput can exportNO_COLOR=1 to their shell’s environment and automaticallydisable color by default in all supported software.

If your software outputs color by default, please consider not doing so.If you insist, please implement this standard to make it easy for yourusers to disable color and then add your software to this list bysubmitting a pull request.

If your software does not output color by default, you do not need to botherwith this standard.

Example Implementation

#include <stdbool.h>#include <stdio.h>#include <stdlib.h>intmain(int argc, char *argv[]){char *no_color = getenv("NO_COLOR");bool color = true;if (no_color != NULL && no_color[0] != '\0')color = false;/* do getopt(3) and/or config-file parsing to possibly turn color back on */...}

Frequently Asked Questions

  1. Why not just set$TERM todumb orxterm without color support?Or change all color definitions in the terminal to print the same color?

    The terminal is capable of color and should be able to print color when instructed.NO_COLOR is a hint to the software running in the terminal to suppress addition of color, not to the terminal to prevent any color from being shown.

    It is reasonable to configure certain software such as a text editor to use color or other ANSI attributes sparingly (such as the reverse attribute for a status bar) while still desiring that other software not add color unless configured to. It should be up to the user whether color is used, not the software author.

  2. How should configuration files and command-line arguments be processedin the presence ofNO_COLOR?

    User-level configuration files and per-instance command-line arguments should override theNO_COLOR environment variable. A user should be able to exportNO_COLOR=1 in their shell configuration file as a default, but configure a specific program in its configuration file to specifically enable color.

    This also means that software thatcan add color but doesn’t by default does not need to care aboutNO_COLOR, because it will only ever be adding color when instructed to do so (as it should be).

  3. Should the presence ofNO_COLOR disable other styling such as bold,underline, and italic?

    No. This standard only signals the user’s intention regarding adding ANSI color to text output.

Color libraries supportingNO_COLOR to disable default color output

Software using these libraries to output color inherently support disablingcolor by default viaNO_COLOR.

SoftwareLanguageDescriptionDate / Version Supported
AnsiLoggerTypeScriptAnsiLogger is a lightweight color logger for Node.js2026-02-06 / 3.2.0
ansisJavaScriptANSI 256/truecolor styling of text in Node.js2021-12-28 / 1.2.2
asaiOCamlCompiler diagnostics2023-11-03 / 0.3.0
AshConsoleGraphics.NETGraphics and interactive interfaces in the terminal2025-03-04 / 2.0.0
AshLib.NETANSI text formatting & more utilities2025-05-07 / 3.2.3
BashkitBashScripting model and framework2023-01-27 / 1.2301.32
bitstringPythonEfficient and flexible handling of binary data2024-04-22 / 4.2.0
cfontsRust, JavaScriptColorful fonts in the console2022-05-28 / 3.0.0
chroniclesNimStructured logging framework with console support2025-07-24 / 0.12.0
CleoPythonBeautiful and testable command-line interfaces2021-01-29 / 1.0.0a1
cli-colorJavaScriptColors and formatting2019-10-09 / 2.0.0
click-extraPythonUtilities for Click, the Python CLI framework2022-04-11 / 2.0.0
cligenNimLibrary to infer/generate command-line-interfaces2020-05-04 / 0.9.46
ColorDebugC, C++Colorful command line output macros2019-02-09
coloredRustColoring terminal output2019-01-05 / 1.7.0
coloredstringsPythonColors & styles for text2025-10-05 / 2.1.0
ColoretteJavaScriptTerminal text color & styles2021-09-17 / 2.0.0
colors-optionJavaScriptColors and formatting based on chalk2021-03-02 / 1.0.0
colourRustMacros for creating colored console output2024-05-13 / 2.0.0
console-ansiJavaScriptConsole coloring and prefixing via Proxy object with ANSI strings2022-06-14 / 1.3.0
crayonRColored terminal output2018-02-08 / 1.5.1
crayon.jsJavaScript, TypeScriptTerminal styling2020-04-10 / 1.0.0
crosstermRustCross-platform terminal manipulation2023-08-06 / 0.27
crystal-lang colorize moduleCrystalAlter text colors and decorations in terminal displays2022-06-06 / 1.5.0
DahliaPythonSimple text formatting package, inspired by Minecraft2022-09-24 / 2.0.0
darvil82.terminal-text-formatterJavaTextFormatter utility to easily color and format text2024-03-11 / 2.1.0
DyeSwiftCross-platform terminal styling2020-06-01 / 0.0.1
FudeJavaScriptTerminal text style formatting2022-06-29 / 3.0.0
Gapotchenko. FX.Console.NETVirtual terminal functionality, console traits, and useful primitives2020-01-15 / 2020.1.15
gchalkGoTerminal string styling with Windows 10 support2021-10-06 / 1.1.1
Getopt::EX::ColormapPerlANSI terminal color and command line option handling2021-09-27 / 1.25.0
gleamy_lightsGleam->Erlang, Gleam->JavascriptColored console output for Gleam2024-09-27 / 2.0.2
GLibCLow-level core library that forms the basis for projects such as GTK and GNOME2025-11-05 / 2.87.1
GNU libtextstyleCLibrary for styling text output with CSS2019-08-13 / 0.21
go-ansiGoEasy text formatting2021-05-18 / 1.4.0
go-supportscolorGoLibrary to detect terminal color support2021-10-06 / 1.1.0
inquireRustBuild interactive prompts2021-08-29 / 0.0.10
kleurJavaScriptFormat terminal text with ANSI colors2020-08-12 / 4.1.0
LogColorPythonColor output in log messages2018-01-24 / 1.2.0
MatthiWare. CommandLineParserC#Command Line Parser2020-07-21 / 0.3.1
Nano ColorsJavaScriptFormat terminal text with ANSI colors2021-09-21 / 0.1.0
NetAF.NETText adventure framework2024-12-03 / 2.9.6
NLog.NETLogging framework2025-02-05 / 5.4.0
oigikiGoANSI color tagging lib2025-12-20 / 2.0.0
paintRubyTerminal colors and effects2020-02-21 / 2.2.0
pastelRubyTerminal output styling2020-07-04 / 0.8.0
Pastel.NETColor console output2019-03-17 / 1.2.0
pfetchShellPretty system information2024-08-01
php-cliPHPPHP library to build command line tools2024-12-03 / 1.3.2
prettyClojureLibrary for helping print things prettily2023-07-20 / 2.0
PyTermGUIPythonTUI framework2022-03-21 / 4.2.0
richPythonRich text and beautiful formatting2022-02-08 / 11.2.0
sgrC++Stream manipulators for colored text output2022-02-28
Spectre.Console.NETCreate beautiful console applications2020-07-21 / 0.1.0
supports-colorRustDetects whether a terminal supports color2022-11-05 / 1.0.2
System.Console.NETRepresents the standard input, output, and error streams for console applications2021-07-10 / .NET 6
Term::ANSIColorPerlColor output using ANSI escape sequences2020-01-17 / 5.01
termcolorRustCross-platform terminal colors2020-01-11 / 1.1.0
termcolorPythonANSI color formatting in the terminal2022-09-11 / 2.0.0
termenvGoText styling, terminal detection and color conversions2021-06-24 / 0.9.0
TextOutputGoControl text output using VT100 terminal codes2019-11-18 / 1.9.1
textus_colorisCColourised console output2021-08-16
WarnaLuaTerminal text styling2024-02-11 / 0.1.0
XConsole.NETColoring, pinning & positioning2022-04-22 / 1.0.5

Software directly supportingNO_COLOR to disable color output by default

SoftwareDescriptionDate / Version Supported
alogviewAndroid logcat Filter2018-10-31
AmmoniteScala Scripting2017-07-03 / 1.0.0
AnsibleIT automation system2021-04-26 / 2.11.0
Ansible NavigatorIT automation interface2021-10-13 / 1.1.0
AptDebian Package manager2021-10-10 / 2.3.11
Archey 4Python system information tool2020-09-26 / 4.8.0
Arduino CLIArduino command line tool2021-09-02 / 0.19.0
AurornisLibrary to simplify command line programs testing2021-11-16 / 1.2.0
BashlyBash command line framework and CLI generator2021-10-26 / 0.6.9
batcat(1) clone with syntax highlighting and Git integration2020-10-02 / 0.16.0
beetsMusic library manager and MusicBrainz tagger2019-05-30 / 1.4.9
bfsBreadth-first version of the UNIX find command2019-05-06 / 1.4.1
Bibtex autocompleteAutocomplete bibtex entries using online data2025-03-03 / 1.4.1
BikeshedSpec/Document Processor2018-07-27 / 0.9
bl-agent-debaterCLI tool for structured debates between AI agents2025-12-31
blockyFast and lightweight DNS proxy2025-11-04 / 0.28.0
BloopCompilation/test server for Scala and Java2018-07-02 / 1.5.3
borgmaticSimple, configuration-driven backup software2024-03-04 / 1.8.9
buildkitConcurrent, cache-efficient, Dockerfile-agnostic builder toolkit2022-07-20
Bullseye.NET library for running a target dependency graph2021-01-01 / 3.6.0
c-rayThe small C raytracer2021-09-24
CakeCross-platform build automation system with a C# DSL2021-03-06 / 1.1.0
CakePHPFull stack framework for PHP2019-12-30 / 4.0.1
CandalfOrchestrate system configuration/setup/management2022-03-22
cdistUsable configuration management2020-06-17 / 6.6.0
ceccompA tool to resolve seccomp just like seccomp-tools2025-11-06 / 3.4
checkitFile integrity tool for Linux and Unix systems2022-09-08 / 0.5.1
chezmoiManage dotfiles across multiple machines, securely2020-05-06 / 1.8.1
ClangC compiler2023-09-19 / 17.0.1
CliFMThe command line file manager2021-14-12 / 1.7
ClipboardThe cut, copy, and paste system for the terminal2022-12-04 / 0.1.2
ComposerPHP package manager2020-01-14 / 1.9.2
CrasCras: The Anti-Procrastination Tool2020-06-05 / 0.1.0
CronieCronie cron daemon project2021-03-19 / 1.6.1
csv2dbCSV database loading tool2019-09-23 / 1.4.0
DataLadData management and publication multitool2019-05-23 / 0.11.5
DDEVDocker-based local PHP+Node.js web development environments2025-07-19 / 1.24.7
DDraceNetworkCooperative multiplayer game2022-02-27 / 5.1
debian-subsystemUse Debian subsystem on other GNU/Linux distributions2021-11-09
DeepfakeHTTPWeb server that uses HTTP dumps as a source for responses2021-09-17 / 1.0.13
denoSecure TypeScript runtime2019-02-09 / 0.2.11
dishA lightweight, remotely configurable monitoring service2025-06-29 / 1.11.3
DiunDocker Image Update Notifier2021-05-26 / 4.17.0
elfinfoUtility for displaying ELF information2020-01-17 / 1.0.1
ElixirDynamic, functional language2020-01-27 / 1.10.0
ElleStatically typed compiled language2025-02-12
ElvishPowerful scripting language and versatile interactive shell2024-02-11 / 0.20.0
enum4linux-ngNext generation enum4linux (Windows/Samba enumeration tool)2020-10-24 / 1.1.0
esbuildJS/TS/CSS bundler2021-05-18 / 0.12.0
exaModern replacement for ls2021-12-06
ezaModern, maintained replacement for ls2021-12-06
F2Safe and fast cross-platform bulk-rename tool2021-05-04 / 1.5.7
fast-asarA faster implementation of Electron’s ASAR archive format2023-10-17 / 1.0.5
fastlaneThe easiest way to build and release mobile apps2020-11-19 / 2.168.0
fdSimple, fast, and user-friendly alternative tofind2020-03-22 / 7.5.0
fetchcommandwrapperIntegrates aria2 withFETCHCOMMAND of portage2025-06-18 / 1.0.0
ffindRust utility to find files and folders2018-03-24
firefox-password-mergerMerge Firefox password CSV exports across machines2025-10-28 / v0.3.0
forest-arboristManage a loosely coupled forest of git or hg repositories2018-04-15 / 1.2.0
fqjq for binary formats2021-12-03 / 0.0.1
fselectUtility for finding files with SQL-like expressions2019-03-08 / 0.6.1
fzfA command-line fuzzy finder2024-06-06 / 0.53.0
gatsby-cliGatsbyJS command line interface2019-08-05 / 2.20.0
gexGit TUI inspired by Magit2023-08-05 / 0.6.1
ghGitHub’s official command line tool2020-04-22 / 0.7.0
ghcupHaskell toolchain installer2021-02-26 / 0.1.13
git-delete-merged-branchesCommand-line tool to delete merged Git branches2020-06-29 / 1.2.0
git-log-treeA fancygit log --graph2025-11-13 / 1.1.0
git-subline-mergeGit merge driver for resolving conflicts2019-07-27
git-taskLocal-first task manager for git repositories with remote sync2024-10-02 / 0.1.1
git-whoGit blame for file trees2026-01-24 / 1.3
GNU gdbThe GNU Debugger2023-09-29 / 14.1
gocryptfsEncrypted FUSE filesystem2021-12-11 / 2.3
gojqPure Go implementation of jq2020-03-20 / 0.10.0
gopassPassword store for teams2018-06-06 / 1.8.0
gplacesSimple terminal based Gemini client2022-06-05 / 0.16.19
GraalVM Native ImageCompile Java applications ahead-of-time into binaries2022-02-28 / 22.1.0
gwenAutomation and robotics for Gherkin2021-11-16 / 3.0.0
h5glanceHDF5 file viewer2024-11-19 / 0.9
HajimeAdvanced Minecraft server wrapper2022-02-27
HomebrewPackage manager for macOS2018-02-27 / 1.5.5
HonoJavaScript framework built on Web Standards2024-03-12 / 4.1.0
HspecTesting framework for Haskell2021-05-12 / 1.8.1
htmltestTests generated HTML for issues2021-01-16 / 0.14.0
HugoFramework for building websites2022-06-16 / 0.101.0
HurlRun and test HTTP requests with plain text and curl2022-09-13 / 1.7.0
hxFuturistic take on hexdump, made in Rust2020-11-22 / 0.4.0
inaryPackage manager for SulinOS2021-10-18
ipcalcA modern IPv4/IPv6 ipcalc tool2025-05-01
irbOfficial Ruby REPL2021-06-21 / 1.3.6
jcConvert output of command-line tools and file-types to JSON2021-12-07 / 1.17.4
jelloFilter JSON and JSON Lines data with Python syntax2021-12-08 / 1.5.0
jqLightweight and flexible command-line JSON processor2023-09-06 / 1.7
jqjqjq implementation of jq2024-02-07
KBSecretSecret manager backed by Keybase and KBFS2018-04-13 / 1.4.0
KibiFeatureful text editor in ≤1024 lines of Rust2025-11-23 / 0.3.2
kittenTiny multi-server automation tool2018-06-06 / 0.2.14
konchPython shell/REPL configuration tool2019-01-19 / 4.0.0
lakeFSManage data as code using Git-like operations2023-07-10 / 0.109.0
latFast file viewer and text formatter2023-04-20 / 0.3.2
lbtFriendly tools for interacting with the LBRY network2022-03-31 / 2.1.2
lcMulti-dimensional, abbreviating ls/file lister in Nim2019-11-18 / 0.9.1
LicensePlistLicense list generator for Apple developer2022-09-20 / 3.23.3
LintianFriendly packaging advice for Debian contributors2021-12-12 / 2.114.87
lrFile list generator2018-01-29 / 1.5.1
lsdThe next gen ls command2022-01-16 / 0.21.0
MatterbridgeMatterbridge2026-02-06 / 3.5.3
mblazeUnix utilities to deal with Maildir2018-01-29 / 1.2
meliTerminal mail client in Rust2019-01-27 / 0.7.2
MeltanoData ingestion, transformation, and management2022-11-08 / 2.9.0
memyManage frequently used files and dirs from the CLI2025-11-12 / 0.15.0
MicrofetchVery fetch tool in Rust for NixOS systems2024-12-19 / 0.4.3
MiddlemanRuby-based static site generator2019-02-18 / 5.0.0
mmCEsimMillimeter Wave Channel Estimation Simulation2023-03-31 / 0.2.1
ModulesDynamic modification of one’s environment2020-04-07 / 4.5.0
muMaildir indexer/searcher2019-02-02 / 1.8.10
Nette TesterTesting library for PHP2020-08-03 / 2.3.3
newsraftFeed reader for terminal2022-08-14 / 0.8
NGLessDomain specific language for bioinformatics2018-10-29 / 1.5.0
NixThe purely functional package manager2021-11-01 / 2.4.0
nnnFile manager2020-04-05 / 4.6
noetherUnit catalogue and calculator for Python2023-08-02 / 1.1
nosttTeletext reader2023-08-03 / 1.3
NoxFlexible test automation2019-04-11 / 2019.4.11
npmPackage manager for JavaScript2018-03-24 / 5.8.0
nvhNode Version Helper2018-08-04 / 4.1.0
oSmall, fast, and limited text editor2020-01-06 / 2.13.2
OCaml compilerThe OCaml programming language compiler2022-03-28 / 4.14.0
Octopus Deploy CLICommand Line Interface for Octopus Deploy2022-11-23 / 0.6.0
opassOffer password suggestions2021-06-12 / 0.9.1
ouchPainless CLI compression and decompression2021-09-17 / 0.3.1
PacstallAUR-inspired package manager for Ubuntu2023-02-27 / 3.7.0
picocliTiny Java command line interface2019-01-05 / 3.9.0
pipewirePipeWire multimedia server2021-03-13 / 0.3.24
PlanckStand-alone ClojureScript REPL2019-05-19 / 2.23.0
Poe the PoetA task runner that works well with poetry or uv2023-09-23 / v0.23.0
PoetryDependency management and packaging in Python2021-05-21 / 1.2.0a1
PowerShellShell and scripting language2021-11-08 / 7.2.0
procsProcess and system query and formatting2019-11-18 / 0.4.0
pulumiProgramming-language-based IaC framework2018-06-04 / 0.14.3
pwndbgA GDB and LLDB plug-in that makes debugging suck less2025-08-16 / 2025.10.10
PyDERASNPython ASN.1 DER/CER/BER library2018-02-14 / 3.1
pydfdf(1) clone with colour output2025-11-27 / 15.0.0
pytestPython testing framework2020-07-28 / 6.0.0
PythonPython REPL, tracebacks anddoctest output2024-05-08 / 3.13.0b1
pytocronContainer cron2025-05-05 / 1.2.0
ripgrepLine-oriented search tool2020-01-11 / 12.0.0
rsmodulesManage one’s environment by the use of modulefiles2018-10-09 / 0.7.3
rsyncyStatus/progress bar for rsync2023-06-30 / 0.2.0
RuffPython linter written in Rust2023-08-09
SaCFunctional array programming language with C like syntax2025-11-19
ScipionCryoEM and CryoET image processing workflow engine2022-07-07 / 3.0.22
ShellSpecFull-featured BDD unit testing framework for shell scripts2020-06-21 / 0.25.0
shuffleCommand line music player2022-02-03 / 1.9.1
sjasmplusZ80/Z80N/GameBoy cross-assembler2022-06-14 / 1.20.0
smenuTerminal selection filter2018-02-05 / 1.0.0
SnowTesting library for C2018-01-24 / 2.3.2
soupaultStatic website generator based on HTML rewriting2021-07-19 / 3.0.0
SphinxThe Sphinx documentation generator2022-03-28 / 4.5.0
sqlfluffThe SQL Linter for humans2025-07-11 / 3.4.2
sqlfmtAutoformatter for dbt SQL2021-11-05 / 0.1.0
SymfonyPHP framework and reusable components2019-11-21 / 4.4.0
taoupFortune implementation2018-09-10 / 1.19
TarantoolIn-memory computing platform2021-10-19
TaskLiteCLI task manager2025-07-26 / 0.5
TeaISOLive ISO generation tools2021-10-22
tealdeerTLDR pages client2020-09-03 / 1.4.0
TelescopeGemini browser2021-06-27 / 0.3
tioA simple serial device I/O tool2024-03-06
treeRecursive directory listing command2022-12-26 / 2.1.0
Tree-SitterA parser generator tool and an incremental parsing library2024-05-05 / 0.22.6
TreeViewerPhylogenetic tree visualisation software2021-02-19 / 1.0.0
Trunk RecorderRadio recorder for P25, SmartNet, and conventional systems2023-12-02 / 4.7.0
tsfmLight TUI file manager2023-07-19 / 2.4.0
twaTiny web auditor with strong opinions2018-11-15 / 1.1.0
txtnishTwtxt microblogging client2018-08-31
ugrepFile pattern searcher2024-04-03 / 5.1.2
undertimeTimezone coordination tool2018-06-06
UnrealIRCdIRC Server2023-03-11
UpCloud CLI (upctl)Command line interface to UpCloud services2022-07-15 / 1.5.1
UPXThe Ultimate Packer for eXecutables2023-10-26 / 4.2.0
whencePrint URL a file was downloaded from2020-06-20 / 0.9.2
woobCommand-line applications to interact with many websites2021-05-13 / 3.1
xhFriendly and fast tool for sending HTTP requests2021-02-28 / 0.8.0
xidocConsistent and powerful markup language2023-01-09 / 2023.1.9
xplrFile manager2021-04-15 / 0.4.4
yewtubeTerminal YouTube client2023-04-22
yt-dlpVideo downloader2023-11-20
zfCommand-line fuzzy finder prioritizing matches on filenames2022-07-02 / 0.5
zigZig compiler2021-12-20 / 0.9.0
zimfwZsh plugin manager2024-11-25 / 1.16.0
zoxideSmarter cd command2020-03-05 / 0.1.0
zypperopenSUSE package manager2022-06-15 / 1.14.53

Disabling color in software not supportingNO_COLOR

SoftwareMethod
Ammoniteamm --color false (Docs)
Arcanistarc --no-ansi COMMAND (Docs)
aria2aria2c --enable-color=false (Docs)
Bundlerbundle COMMAND --no-color (Docs)
Chalkexport FORCE_COLOR=0 (Docs)
CMakeSetCMAKE_COLOR_DIAGNOSTICS toOFF (Docs)
Cocoapodspod COMMAND --no-ansi (Docs)
FFmpegexport AV_LOG_FORCE_NOCOLOR=true (Docs)
GCCexport GCC_COLORS= or-fno-diagnostics-color (Docs)
Gitgit config --global color.ui false (Docs)
GoAccessgoaccess --no-color (Docs)
GStreamerexport GST_DEBUG_NO_COLOR=true or--gst-debug-no-color (Docs)
luacheckluacheck --no-color (Docs)
Lynxlynx -nocolor (orshow_color=never in.lynxrc)
Mercurialhg --color=never (orDocs for .hgrc)
Midnight Commandermc --nocolor
Packerexport PACKER_NO_COLOR=true
pre-commitpre-commit --color=never orexport PRE_COMMIT_COLOR=never (Docs,RejectedNO_COLOR Request)
Puppetpuppet agent --color false (Docs)
Radareradare2 -e scr.color=0
RSpecexport SPEC_OPTS=--no-color
Ruby (tests)export RUBY_TESTOPTS=--color=never
The Silver Searcherag --nocolor (RejectedNO_COLOR Request)
Thorexport THOR_SHELL=Basic (Docs)
util-linuxtouch /etc/terminal-colors.d/disable (Docs)
Vimvim '+set t_Co=0'
zellijzellij --no-formatting (GitHub Issue #3057)

[8]ページ先頭

©2009-2026 Movatter.jp