When creating a new attribute field in QGIS, these three options are offered for integer numbers but what is the difference between Integer 16bit, 32bit and 64bit in QGIS?
A 16 bit Signed Integer can house a number from −32,768 to 32,767 Unsigned: 0 to 65,535.
A 32 bit Signed Integer can house a number from −2,147,483,648 to 2,147,483,647 Unsigned: 0 to 4,294,967,295.
A 64 bit Signed Integer can house a number from −9,223,372,036,854,775,808 to 9,223,372,036,854,775,807 Unsigned: 0 to 18,446,744,073,709,551,615.
Integers in QGIS (3.10+) are Signed unless otherwise stated.
So it depends on the size of the numbers you are storing.
Factors that determine which datatypes are available (not just in) QGIS
Field types are not QGIS specific, but depend on the file/datebase format you use. The options vary for different file formats. Shapefile is an old format, published in 1998 and has several limitations, whereas GeoPackage (used as default file format for vectors since QGIS 3.0) is a newer format, first released in 2014, thus with much lesser limits.
Thus QGIS can't offer the same data types for every file format without violating the requirements for each file format. Also consider that for converting file formats, QGIS uses libraries like GDAL/OGR, so it also relies on these dependencies what QGIS can offer (and what not).
So in principle, it depends on all those software components implicated (Program, libraries, file formats) and it's respective version what is available and what not. Just to make an example, see the comparison between Shapefile and Geopackage:
What you can find in the QGIS documentation about data types
The QGIS documentation for 3.16 reads:
Supported types are
Whole number(both integer and integer64),
Date and time,
Dateattributes are supported.
General support of data types
See here for the data types supported by Geopackage (scroll down to Table 1. GeoPackage Data Types) - it mentiones between else:
8/16/32/64-bit signed two’s complement integer
See here for the data types supported by Shapefiles from the GDAL documentation:
Only Integer, Integer64, Real, String and Date (not DateTime, just year/month/day) field types are supported. The various list, and binary field types cannot be created
And see this detailed description of the Shapefile format by the Library of Congress:
The Shapefile format stores integer and double-precision numbers. The ESRI Shapefile Technical Description refers to the following types:
Integer: Signed 32-bit integer (4 bytes) Double: Signed 64-bit IEEE double-precision floating point number (8 bytes) Floating point numbers must be numeric values.
Screenshot: Geopackage (left), temporary scratch layer (middle), Shapefile (right) -
Ganze Zahl means
Whole number (my QGIS is in german):