An API is available to generate UUID.
Generate UUID.
UUID versions: v1, v3, v4, v5.
Limit: Number of UUID to generate (Max: 1000, Default: 1).
const request = new XMLHttpRequest(); request.open("GET", "https://api.extendsclass.com/uuid/v4?limit=10", true); request.onreadystatechange = () => { }; request.send();
[ "aa5d758e-7646-45a6-bd67-7916eac77301", "4b60125d-9abf-4838-a348-c50bad1810ac", "d1fe1f34-9d6e-44d6-a7ed-86976cec26a0", "cd3a77fd-647b-4ef3-aea5-0192334c442f", "024365c4-3e8d-416d-9539-44cb5e3f7cef", "cb7332b7-5bea-4cb5-b85c-c13e403fbfff", "dafb6e2a-9e62-43f8-a5c7-93e2a368a9a2", "d75373fc-1862-4d3c-97cc-d0ce657cacd8", "7f96802b-eae9-473c-a8b6-38280914ff6d", "af9f326d-00b1-4234-bb19-06b1eeff9c1f" ]
UUID version is not available
Too many uuid to generate
An UUID (universally unique identifier) is a 128-bit number used to identify information.
UUID are represented as 32 hexadecimal digits, displayed in groups separated by hyphens (total of 36 characters with hyphens). Form: 8-4-4-4-12. For example: d036ac19-1269-49e0-8d3d-2a9ebb67ba6d
There are fives versions of uuid, and each version may be more appropriate than the others in specific use cases.
This tool allows you to generate UUID online.
An UUID is automatically generated as soon as you access this page.
You can also generate multiple UUIDs at once. See Bulk section.
You can also generate UUID with a REST API. See API section.
This online UUID generator uses the npm module uuid.
In development, we often use identifiers for all kinds of data/objects. The question is whether a simple identifier is sufficient or whether you need a UUID.
A UUID may be needed in the following cases (non-exhaustive list):
When it is not useful, it is not recommended to use an UUID. Indeed, this type of identifier takes 36 characters, which can deteriorate performance. This impacts the amount of data to store, but also to index. In addition, integer comparison is more efficient than character string comparison. These drawbacks are all the more problematic as the number of records increases.
So when it is not necessary it is better to use an id (Single database, natural key, ...).
Comments