The invention belongs to the technical field of network access control, and discloses a token generation method and device and a token check method and device. The token generation method in the invention is applied to a server cluster. The method comprises the steps of: receiving the identification character string of a token needing to be checked sent by a client side; searching a key of the identification character string in a token database, wherein the token database stores a generated token, including the identification character string stored as the key and an information character string stored as the key value of the corresponding value; after the key of the identification character string is searched in the token database, obtaining the key value of the key, and then, setting thekey value of the key stored in the token database to an invalid value; and, detecting the obtained key value of the key, when the key value is not the invalid value, representing that a check resultis passed, and, when the key value is the invalid value, representing that the check result is not passed. By means of the token check method and device disclosed by the invention, one-time effectiveness of the token is ensured through a simple and convenient mechanism.