In the 20th century, especially in World Wars I and II, typical capital ships would be battleships, battlecruisers, and in WWII, aircraft carriers (though it took until late 1942 for carriers to be universally considered capital ships). All of the above ships were close to 20,000 tons displacement or heavier. Heavy cruisers, despite being important ships, were not considered capital ships.
An exception to the above in World War II was the Deutschland-class cruiser. Though this class was technically similar to a heavy cruiser, albeit with considerably heavier guns, they were generally regarded as capital ships (hence the British label "Pocket battleship"). The Alaska-class cruisers, despite being oversized heavy cruisers and not battleships/battlecruisers, were also considered by some to be capital ships.
During the Cold War, a Soviet Kirov-class large missile cruiser had a displacement great enough to rival WWII-era capital ships, perhaps defining a new battlecruiser for that era.
In the 21st century, the aircraft carrier is the last remaining capital ship, with firepower defined in decks available and aircraft per deck, rather than in guns and calibers. The United States has undeniable supremacy in both categories of aircraft carriers, possessing not only 11 active duty supercarriers each capable of carrying and launching nearly 100 tactical aircraft, but an additional 12 amphibious assault ships every bit as capable (in the "Sea Control Ship" configuration) as the light VSTOL carriers of other nations.
Ballistic missile submarines (or "boomers"), while important ships and in tonnage are similar to early battleships, are usually counted as part of a nation's nuclear deterrent force and do not share the sea control mission of traditional capital ships. (Although in some navies (Royal Navy and United States Navy), ballistic submarines are given names typically formerly given to battleships).
The definition of "capital ship" was formalized in the limitation treaties of the 1920s and 30s; see Washington Naval Treaty, London Naval Treaty, and Second London Naval Treaty.
Before the advent of the all-steel navy in the late 19th century, a capital ship was a warship of the First, Second or Third rates:
Frigates were ships of the fourth or fifth rate; a corvette was a ship of the sixth rate.