If your transaction is stuck, try resetting your MetaMask by clicking the account icon on the top-right corner of MetaMask, then go to →
Select Advanced→ Scroll down and click
Reset Account. Please note that resetting your account will NOT disrupt your funds or wallet address. Alternatively, if the “Cancel” button isn’t helping, you can use the "custom transaction nonce" method that works by essentially overwriting the stuck transaction with another, higher-priority transaction to clear your backlog.
If your transaction failed, it's either because you don't have enough slippage or don't use enough gas. You'll have to increase your allowed slippage to account for the fee taken during the swap. Click on the gear
icon for settings and adjust slippage tolerance accordingly.
You can use an Explorer to track your transaction status. These are the relevant Explorers: