> ## Documentation Index
> Fetch the complete documentation index at: https://companyname-a7d5b98e-ton-storage.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Type system overview

The Tolk type system is designed with the specifics of TON in mind.

Since on-chain data and communication rely entirely on cells,
the system focuses on binary serialization and clear data relationships.

Programs run on a stack-based virtual machine ([TVM](/tvm/overview)),
which imposes specific rules on how values are represented at runtime.

This section describes all the types in Tolk language:

* [numbers](/languages/tolk/types/numbers) — int, int32, uint64, coins, etc.
* [boolean](/languages/tolk/types/booleans) — true/false and logical operators
* [address](/languages/tolk/types/address) — internal, external, and none addresses
* [cells](/languages/tolk/types/cells) — and also slices, builders, and raw bits
* [strings](/languages/tolk/types/strings) — not a native type, emulated using slices
* [structures](/languages/tolk/types/structures) — group several fields into one entity
* [type aliases](/languages/tolk/types/aliases) — similar to TypeScript and Rust
* [generics](/languages/tolk/types/generics) — any struct can be generic \<T>
* [enums](/languages/tolk/types/enums) — a distinct type containing integer variants
* [nullable types](/languages/tolk/types/nullable) — with null safety and smart casts
* [union types](/languages/tolk/types/unions) — a variable holds one of possible values
* [tensors](/languages/tolk/types/tensors) — multiple values placed sequentially on the stack
* [tuples](/languages/tolk/types/tuples) — multiple values stored in a single TVM tuple
* [maps](/languages/tolk/types/maps) — key-value dictionaries
* [callables](/languages/tolk/types/callables) — first-class functions
* [void and never](/languages/tolk/types/void-never) — both mean "absence of a value"

An article ["Type checks and casts"](/languages/tolk/types/type-checks-and-casts)
describes casting types with unsafe `as` operator.

For a summary of how types are represented on a TVM stack,
follow [Overall: TVM stack representation](/languages/tolk/types/overall-tvm-stack).

For a summary of how types are serialized and their relation to TL/B,
follow [Overall: serialization](/languages/tolk/types/overall-serialization).
