> For the complete documentation index, see [llms.txt](https://dexx.gitbook.io/dexx-tutorial-book/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dexx.gitbook.io/dexx-tutorial-book/q-and-a/why-are-gas-fees-so-expensive.md).

# Why Are Gas Fees So Expensive?

**What is Gas?** \
Gas fees are the charges you pay for each transaction to validators and the blockchain network. Every transaction requires gas, and these fees are not collected by DEXX.\
\
\
**Why Are Gas Fees for Buying Tokens Much Higher Than for Transfers?** \
Gas fees correlate with the complexity of the operation, the computational resources needed, and the storage requirements on the blockchain. Buying tokens involves intricate contract logic and frequent state updates, whereas transferring tokens is simply moving assets from one address to another, which is much simpler and requires less computational power.*\*Note: Some special tokens have particularly complex smart contracts, resulting in unusually high gas fees for each transaction.*&#x54;his is why gas fees for purchasing tokens are significantly higher than those for transfers.\
\
\
**What Are Priority Fees and Speed Modes?** \
Priority fees (often called "tips") were introduced in Ethereum's EIP-1559 upgrade. This mechanism allows users to pay an extra fee besides the base gas fee to get their transactions processed faster. Transactions with higher gas fees are typically prioritized, so users can control how quickly their transactions are confirmed by adjusting the gas fee. You can select normal, quick, or priority modes in the transaction settings to adjust the fees and speed. Just keep in mind that lower gas fees can lead to very slow processing times and might even result in transaction failures. During high-demand periods, like when token launches or the market is blooming, lower priority fees can cause transactions to fail.\
\
\
**Is Gas a Fixed Value?** \
No, gas prices fluctuate dynamically based on network congestion. When the network is busy, gas fees rise to attract validators to prioritize transactions; when it’s quieter, gas fees decrease. The gas price displayed on the transaction page reflects the previous second's price and can change rapidly, so it's only a rough estimate.\
\
\
**Why Do Gas Fees Fluctuate So Much?**\
Gas fees on Ethereum can vary widely due to several factors, including the supply-demand relationship of the network, market bidding dynamics, transaction complexity, major market events, and the strategies validators use to pack transactions. As trading demand grows, gas fees can spike quickly, especially during times of congestion.Historically, gas fees have hit over 1000 Gwei, and in extreme cases, they have briefly exceeded 2000 Gwei. Typically, at around 30 Gwei, the gas price for each token transaction ranges from $20 to $50.\
\
\
**Why Was I Charged Gas Fees Even If My Transaction Failed?** \
Gas fees represent the computational costs on the blockchain, and they are mandatory for executing transactions or contracts. DEXX does not collect these fees. Once your transaction information is packed on-chain by DEXX, the blockchain processes the calculation and determines that your transaction can't be completed, resulting in a failure. Therefore, gas fees are non-refundable, even if the transaction fails.


---

# 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:

```
GET https://dexx.gitbook.io/dexx-tutorial-book/q-and-a/why-are-gas-fees-so-expensive.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
