Questions tagged [fees]

Questions related to the transactions fees and gas costs in Ethereum

Filter by
Sorted by
Tagged with
0 votes
2 answers
38 views

A guide to solve some challenges in building a blockchain game

We are designing a blockchain game, currently we have encountered some challenges in the wallet and interaction with the smart contract and token transfer that I would like to consult you about. First ...
0 votes
0 answers
15 views

Who is earning the Safe Paymaster fees?

I am running a wallet project where the business model is to earn revenue by Paymaster fees in ERC20 tokens. Will Safe allow me to set my own Paymaster fees and will Safe allow me to earn revenue that ...
3 votes
3 answers
306 views

Sandwich Attack: Why do they use so high gas fees on sells?

I am currently watching into vulnerabilities and different threats for DEXes. I found some sandwich attacks or front running, that use moderate-high Gas Fees on Buy and crazy high Gas fees on the sell....
1 vote
1 answer
43 views

Uniswap V2 Transfer Tax Math

The normal question to get the amount of token received when doing a Uniswap V2 swap is amount_out = 0.997 * amount_in * reserves_out / (reserves_in + 0.997 * amount_in) I want to adjust this equation ...
0 votes
1 answer
523 views

Insufficent network fees

I get the message, "The ETH balance in your parent account is insufficient for network fees" when I try to send my ECR20 Matic tokens from my Leger to my coinbase account. Instead of sending ...
2 votes
2 answers
2k views

Dynamic arrays VS mappings when it comes to gas usage?

I'm puzzled what is more efficient to use, from the point of gas consumption (storage and execution), dynamic array or the mapping and element counter. To be more clear, I'm not asking the basic data ...
2 votes
1 answer
389 views

How long did a transaction spend in the mempool?

I'm trying to create some statistics on how long a transaction spends in the mempool before being included in a block, so I can reason about future gas prices. It would appear transactions in Ethereum ...
0 votes
1 answer
496 views

FX6 and "ERC-20 Block Link Fee" or My Funds are being held Hostage

I was "tricked" into using FX6/Sundell, but that is a story for another thread. I was able to move my funds out of FX6/Sundell into my Coinbase Wallet. But, it appears FX6/Sundell were able ...
0 votes
0 answers
24 views

Is there anyway to reduce gas fee for uniswap v3 ExactOutputSingleParams?

Question is simple. Is there anyway to reduce gas fee for ExactOutputSingleParams ? function swapExactOutputSingle(uint256 amountOut, uint256 amountInMaximum) external returns (uint256 amountIn) { ...
2 votes
2 answers
6k views

Max Priority Fee and Max Gas Fee difference and definition

What is the definition of max priority fee and max gas fee in EIP-1559 enabled Ethereum?
0 votes
0 answers
8 views

How can l compare tx fee for main network and testnet

I have a contract on testnet and how can l learn how much tx fee will be on main network with same contract. Is there any way to get this information.
0 votes
1 answer
238 views

How accurately does sepolia gas/transaction price correlate with ETH

I'm currently using Sepolia testnet while learning how to mint nft's through javascript, and wondering how accurate the gas price/transaction fee's are for when I switch to using real ETH. I'm making ...
0 votes
2 answers
22 views

Gas price error when minting a created token

I created the following token https://bscscan.com/address/0xb3497b2a0368e9b96ace9b6ad3033f440457d1b9. In addition to the written code, the imported calls were ERC20 such as import "@openzeppelin/...
0 votes
1 answer
61 views

How much does it cost to clog the Ethereum Network exactly?

Currently the largest gas guzzler to clog the Ethereum network is the Mint contract below. Supposedly there are users purposely causing high gas prices using this function. Why would anyone do this ...
0 votes
0 answers
134 views

How to get taxation feature on token transactions on uniswap?

I have an ERC20 token contract deployed on mainnet. // SPDX-License-Identifier: MIT pragma solidity <=0.9.0; import "@openzeppelin/contracts/token/ERC20/ERC20.sol"; import "@...
0 votes
1 answer
274 views

Get Price via Uniswap V3 depends on Pool's fee

I'm currently developing a smart contract with access to Uniswap V3's QuoterV2 contract. I'm interested in obtaining the most accurate price of tokenB in terms of tokenA: quoter.quoteExactInputSingle(...
1 vote
2 answers
1k views

Ethereum TX Fees/Gas Gambling Calculation

I'm wondering if there's a better way of handling the transaction fee limit. As I understand it at the moment, it's basically a gamble. You wager an amount. If it is too low, you lose it all when it ...
0 votes
1 answer
1k views

Getting Fail with error 'TransferHelper: TRANSFER_FROM_FAILED' while trying to swap part of tokens during transfer

I have created ERC20 token and want to modify transfer function so that swaps part of transferring amount to another token. I'm using OpenZeppelin ERC20 contract. // SPDX-License-Identifier: MIT // ...
0 votes
0 answers
30 views

Launched my ERC20 contract on both Ethereum and PulseChain, when updating fees on Pulsechain i recieve this error? Please help

invalid BigNumber string (argument="value", value="", code=INVALID_ARGUMENT, version=bignumber/5.7.0) I get this message when updating the fees on buys/sells. Can anyone help? ...
0 votes
1 answer
15 views

Buying ethereum on Metamask or Coinbase

What is the cheapest way to buy ethereum? Straight through metamask or through coinbase and then transfer it to metamask?
0 votes
0 answers
77 views

Calculate uniswap v3 fees for position from swap events

I need to calculate uncollected fees for uniswapV3 position let's say from yesterday. I scanned for all swap events in the liquidity pool and saved them to my DB. Also I have in the database all ...
2 votes
1 answer
782 views

gas fee on OpenSea

First, I'm brand new to the Ethereum platform, so I do apologise if any of the following is considered stupid questions. Now, I will ask my question anyway I am setting up the first sale of one of my ...
0 votes
0 answers
20 views

Fantom cannot approve spending USDC token

I am doing simple approve operation on USDC token in Fantom network. Here is my payload: functionParams { from: '0xd775b00b5cf6e954aed8408202367a1bae6ac55f', to: '...
0 votes
1 answer
112 views

Can't clear pending transaction with current nonce getting an rpc error

Somehow my transaction was sent with extremely low gas fees from ETH mainnet to zkSync bridge. Is stays forever on pending I saw this and tried to cancel it/speed it up but it did not work. I tried to ...
1 vote
2 answers
357 views

Why ETH gas fee is still expensive >$5 - $10 after sharding + POS?

I just notice that ETH charges $40 for a tx at the time POW + high demand $5-$10 at the time POW + avg low demand And $5-$10 at the time POS + low demand (current 2023) So can you explain more why the ...
0 votes
0 answers
38 views

Ether gas fees, environmental impact?

It is my understanding that gas fees paid in Ether are more like tips given to validators to prioritize their tasks when there is a high volume of traffic. For example, Investopedia states here: &...
0 votes
0 answers
22 views

80% of tax fees in uniswap

I PUT 27 euros to uniswap and they take 6 euros in fees for PUT it in the wallet and then I want to swap my Ethereum and it says that I only have 3 euros to swap in ethereum. It’s normal that they ...
0 votes
1 answer
260 views

EIP-1559: Possible to ONLY use maxPriorityFeePerGas, and no other gas, to pay for a transaction?

My system keeps track of ETH wallets in a local DB. It is preferable that I know exactly what the fee is beforehand, so I can update the DB before broadcasting, and then rollback if anything goes ...
15 votes
4 answers
47k views

How to calculate transaction fee?

For calculating the transaction fee using web3js I am using it's gas price: eth.getTransaction("txhash").gasPrice multiplied by how much gas was actually used: eth.getTransactionReceipt("txhash")....
15 votes
5 answers
11k views

How to transfer the whole balance of an account?

If I have an account with 5 ETH, can I send the full account balance of 5ETH to another account and have exactly 5ETH received on the second account ? I understood that it will fail because I have no ...
2 votes
1 answer
126 views

Base fee determination in Polygon / tâtonnement

I am currently stuck in my understanding of the base fee pricing. According to the [wiki](https://ethereum.org/en/developers/docs/gas/#block-sizestrong text) of the Ethereum mainnet, the base fee is ...
0 votes
1 answer
53 views

Getting incorrect GasPrice from tx type 2

Having transaction sent from Metamask (ropsten network): 0xddd70e7d8dbd3cf5c0618501911b045464ae2087bd537aa538f34b8c9600dcc7 I'm watching transactions in new blocks using golang, and when tx match ...
2 votes
1 answer
557 views

swapExactTokensForETH transaction reverted, `UniswapV2: K` error (with gas wasting), selling with Uniswap GUI works fine

Facing reverting swapExactTokensForETH transaction using web3js. Tried different ways. Probably, it is important to note, this failed transaction uses a relatively large amount of Gas Fees. The code ...
2 votes
0 answers
637 views

Trying to get buy and sell fee for any BEP20/ERC20

I'm trying to understand how https://honeypot.is/?address=0x317a214777a04576b0287fc8abc98738b27815c8 works. I'll link all info from the BSC checker but is almost the same for ETH They are using a ...
1 vote
2 answers
1k views

EIP1559. Transaction type 0 and type 2

After the activation of the London hard fork, EIP1559 proposed a new type of transaction - type 2. Such transactions have a base fee that will be burned, and maxPriorityFeePerGas, which incentivizes ...
1 vote
0 answers
25 views

Send dalayed EIP1559 transaction

I'm trying to generate new EIP1559 transaction at 11:00. My goal is that after the transaction was sent I'll get 0 balance on the wallet. But the issue is that after I sign this transaction I'll ...
1 vote
1 answer
136 views

What are the events that mint new ETH?

I’m trying to better understand the rewards and minting processes for ETH POS so I can potentially apply the logic to a protocol I’m building. My question is what events lead to minting new ETH? My ...
0 votes
1 answer
72 views

cost fee according to the size of a mapping

I try to improve my skills in solidity programming, for that i try to ode a dynamic NFT, which evolve according to 2 variables stored in a mapping. struct NFTInfo { uint32 nbOwners; ...
0 votes
1 answer
1k views

Do NFT bids, and refunds from being outbid, have the same transaction/gas fees?

If I bid on crypto art to the tun of $50 in transaction/gas fees, can I expect the same amount of fees to incur if I am outbid on that item, and the NFT platform refunds me my bid? $50 fee there, and $...
0 votes
0 answers
52 views

Is there a way for the fee payer to be another account web3py

Is it possible on the ETH chain to have a transaction signed by account_1 but send it and pay fee by account_2? i know this is possible in solana but i cant find an answer in Ethereum. What i would ...
0 votes
0 answers
776 views

How to calculate the buy/sell fee or tax on the pairing token within the erc20 token - solidity

I am trying to develop an ERC20 token that has a marketing fee/tax for both buy and sell. The marketing fee/tax must be calculated and paid in USDC which will be paired with my ERC20 token on the ...
1 vote
1 answer
926 views

Does ethers.js automatically calculate gas costs?

const contractAddress = "Contract Address"; const ABI = "ABI data JSON" const Web3 = require("web3"); const transaction = { 'from' :account.address, 'gas': ...
1 vote
2 answers
95 views

How does ethereum testnets prevent DoS attack without expensive fees

Gas fees, among other things, make spamming expensive and thus prevent attackers to emit thousands of transactions. Since testnets have no fees (or "free" tokens), what really prevents ...
0 votes
1 answer
150 views

unit of tx.gasprice and block.basefee

I'm querying tx.gasprice and block.basefee on a mainnet fork pinned to block 15823986 -kind of recent one at the time of writing- and I'm getting 1991927019 and 991927019 respectively. If these values ...
1 vote
1 answer
348 views

What is the difference between Miner Tip and maxPriorityFeePerGas

Yesterday I noticed 2 arbitrage transactions on Uniswap V3 in the same block and pools: 1)https://etherscan.io/tx/0x1933479aad430fc3b0acfb9394d138e62d19d1a15437a52a807ca4af9bad7591 2)https://etherscan....
1 vote
2 answers
19 views

Does "Transaction"'s From pay for Gas of party of the transaction?

There are some transfer for example native currency(ETH, MATIC), ERC-20, 721 tokens and stuff like that on a transaction then there are several "From" address. I am confused which address ...
1 vote
0 answers
314 views

How do I calculate the transaction fee on the Optimism network

I have this transaction hash https://optimistic.etherscan.io/tx/0x9b8f0d63adb5c633baff74b642331d0015ea207134bd3f7f526a9b89d5dfae27 How did optimism calculate the 0.05c USD transaction fee Can someone ...
0 votes
1 answer
188 views

Priority Fee for Legacy Transaction

Good day friends, I'm curious if there is a way to see what the priority fee is on a legacy transaction. I always remember using metamask and being able to select options to increase the speed, but ...
0 votes
1 answer
25 views

Create Function Gas Fees to have a Dynamic Fees based on Gas Fees

is it possible in solidity create a function to estimate a gas fee and apply a % of fees based on gas fees ? Thanks
2 votes
1 answer
4k views

How to pay ERC20 gas fee (which is payed in ETH) from another wallet?

I have a ERC20 token on a wallet called ETH (Ethereum Meta) but I don't have any ETH on that address so I can't transfer the ERC20 tokens because I cant pay the gas fee. I have some ETH on another ...

1
2 3 4 5 6