Pinyin is the official romanisation of Mandarin Chinese. It can be written three ways, and hanzi.ac accepts all three in search.

StyleExampleUse
Tone marksnǐ hǎoTextbooks, dictionaries
Tone numbersni3 hao3Fast typing, flashcards, data files
No tonesnihaoChinese input methods, casual typing

Tone numbers

Write the tone as a digit after each syllable: 1 for first tone, 2 second, 3 third, 4 fourth, and 5 (or nothing) for the neutral tone.

  • mā → ma1 · má → ma2 · mǎ → ma3 · mà → ma4 · ma → ma5
  • 谢谢 → xie4 xie5

Typing ü

The vowel ü appears after n and l: nǚ (woman), lǜ (green). Keyboards rarely have it, so two conventions are used:

  • v in place of ü: lv4 = lǜ. This is what Chinese input methods use.
  • u: in place of ü: lu:4 = lǜ. This is the convention in CC-CEDICT data.

After j, q, x and y, the dots are never written: ju, qu, xu, yu always stand for ü.

Typing tone marks

  • Windows / macOS: add a pinyin input method (for example “Pinyin – Simplified”) and type the Chinese characters, or use an accent-typing tool.
  • Phones: on most keyboards, long-press a vowel to choose a toned version.

For searching, typing tone marks is rarely worth the effort: numbers or no tones give the same results.

Searching hanzi.ac with pinyin

All of these find 你好:

  • nihao
  • ni hao
  • ni3hao3
  • nǐhǎo

Without tones you get every word with those syllables, most common first. Adding tone numbers narrows the list: ma lists many words, ma3 lists words read mǎ. You can also search in English (bank) or paste Chinese text; a phrase such as 我想喝咖啡 is split into the words it contains.