> For the complete documentation index, see [llms.txt](https://hub.bsvblockchain.org/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://hub.bsvblockchain.org/wiki/cryptography-and-keys/cryptography/nonce.md).

# Nonce

Nonce is shorthand for 'Number Used Once' and is a number that is consumed in an action and not recorded. In this case, the true 'number' is the full block header which is hashed as a single string however the 'Nonce' field is the only part which changes during process of hashing a given block header. The "nonce" in a Bitcoin block header is a 32-bit (4-byte) field, whose value is adjusted by Miners during the Proof of Work process in an effort to generate a block hash less than or equal to, the current target of the network. The rest of the fields, with the exception of the timestamp, may not be changed, as they have a defined meaning. Any change to the block data (such as the nonce) will make the block hash completely different. Since it is [believed infeasible](https://en.wikipedia.org/wiki/Cryptographic_hash_function) to predict which combination of bits will result in the right hash, many different nonce values are tried, and the hash is recomputed for each value until a hash less than or equal to the current target of the network is found. The target required is also represented as the difficulty, where a higher difficulty represents a lower target. As this iterative calculation requires time and resources, the presentation of a block with a valid nonce value constitutes proof of work.

1. Attribution This content is based on content sourced from <https://en.bitcoin.it/wiki/Nonce> under [Creative Commons Attribution 3.0](https://creativecommons.org/licenses/by/3.0/). Although it may have been extensively revised and updated, we acknowledge the original authors.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://hub.bsvblockchain.org/wiki/cryptography-and-keys/cryptography/nonce.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
