2

I am using the phantom-wallet-adapter in a Next.js app. It works fine and connects to my wallet when running the app locally. However, when running it remotely (for example, when connecting to the deployed frontend, or simply connecting to the IP address and port of my PC from another PC), it keeps giving WalletNotReadyError, even though I have the phantom extension installed on the browser accessing the app. I have noticed that while running the remote, window.solana is undefined, which, to my understanding, is needed in order to connect the wallet to the app.

2
  • Did you ever figure out what the issue was here? I'm having the same problem with NextJS 13 deployed in Docker on AWS.
    – harkl
    Commented Feb 17, 2023 at 5:07
  • 2
    Yes. The issue is that the solana wallet adapter refuses to work on HTTP unless it's locally. In order to get it to work make sure you access your next app via HTTPS Commented Feb 18, 2023 at 6:29

1 Answer 1

4

The issue is that the solana wallet adapter refuses to work on HTTP unless it's locally. In order to get it to work make sure you access your next app via HTTPS

2
  • i use ngrok. it doesnt work. is it really deploy on website via aws ?
    – Jerry
    Commented Mar 2, 2023 at 7:37
  • You can deploy via anything you want as long as the domain is HTTPS and not HTTP. Commented Mar 3, 2023 at 8:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.