Universal Chess Interface Explained

The Universal Chess Interface (UCI) is an open communication protocol that enables chess engines to communicate with user interfaces.[1] [2]

History

In November 2000, the UCI protocol was released. Designed by Rudolf Huber and Stefan Meyer-Kahlen, the author of Shredder, UCI rivals the older "Chess Engine Communication Protocol" introduced with XBoard/WinBoard.

In 2002, Chessbase, the chess software company which markets Fritz, began to support UCI, which had previously been supported by only a few interfaces and engines.

, well over 300 engines are known to directly support UCI.

Design

By design, UCI assigns some tasks to the user interface (i.e., presentation layer) which have traditionally been handled by the engine (at the business layer) itself.

Most notably, the opening book is usually expected to be handled by the UI, by simply selecting moves to play until it is out of book, and only then starting up the engine for calculation in the resulting position. UCI does not specify any on-disk format for the opening book. Different UIs usually have their own proprietary formats.

While the UI can also take responsibility for handling endgame tablebases, this is arguably better handled in the engine itself, as having tablebase information can be useful for considering possible future positions.[3]

Stefan-Meyer Kahlen's UCI protocol in Shredder uses a variation of long algebraic notation for moves. A "nullmove" from an engine to a GUI should be sent as 0000.[4]

Examples

Commands

There are many commands used to communicate with an engine. [5]

UCI Commands List!Command!Usage!Description!Response
quit<nowiki> quit </nowiki>Closes the chess engine
uci<nowiki> uci </nowiki>|Tells the engine to switch to UCI mode|uciok|-|ucinewgame|<nowiki> ucinewgame </nowiki>|Used to let the engine know that the next position it receives will be from a different game.||-|isready|<nowiki> isready </nowiki>Used to synchronize the engine. Use after sending a command that might take some time.readyok
setoption<nowiki> setoption name <id> [value <x>] </nowiki>|Used to change the internal parameters of a chess engine.||-|position|<nowiki> position [fen <fenstring> | startpos ] moves <move1> .... <movei></nowiki>Used to tell the engine to setup the provided position.
go<nowiki> go [infinite | depth <depth> | nodes | mate] searchmoves <move1> .... <movei> ponder wtime <x> btime <x> winc <x> binc <x> movestogo <x> nodes <x> movetime <x> perft <x></nowiki>Tells the engine to start calculation.

Notes and References

  1. Web site: Chess engines. Business World Online. 2017-04-06. 2018-06-14. 2021-01-28. https://web.archive.org/web/20210128204424/https://www.bworldonline.com/content.php?id=143346. dead.
  2. Web site: Lichess embraces blind players with new chess site features. Torres, JC. SlashGear. 2014-06-23. 2018-06-14.
  3. Book: Chess Life. 2003. United States Chess Federation.
  4. Web site: UCI protocol. www.wbec-ridderkerk.nl. 2018-06-14.
  5. Web site: 2025-11-23 . UCI & Commands Stockfish Docs . 2026-02-02 . Stockfish Documentation . en-US.