# \[Archive\] Does Web3Auth support layer 2 network - Scroll?

**URL:** <https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218>\
**Category:** Embedded Wallets (Web3Auth)\
**Created:** [September 20, 2024, 3:44pm UTC](https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218 "2024-09-20T15:44:48Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![leeweixuan39](https://avatars.discourse-cdn.com/v4/letter/l/3da27b/32.png) [@leeweixuan39](https://builder.metamask.io/u/leeweixuan39)\
**Post date:** [September 20, 2024, 3:44pm UTC](https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218/1 "2024-09-20T15:44:48Z")

</div>

> **🏛 Archived Content from Web3Auth Community**
> 
> This topic was originally posted by **leeweixuan39** on 9/20/2024.  
> This content has been migrated from our previous community forum to preserve valuable discussions.

* * *

I have tried to run the EVM demo: [https://evm-modal-example.vercel.app/](https://evm-modal-example.vercel.app/)

and I’m using Scroll Sepolia network: [Setup | Scroll Documentation](https://docs.scroll.io/en/user-guide/setup/)

but when I tried to click the Get Private Key it just return me this error:

[![image](https://canada1.discourse-cdn.com/flex011/uploads/metamaskbuilderhub/original/1X/65a3ea3c6e62109cc2413449e56e89757cfa49ea.png)
image724×181 2.09 KB
](https://web3auth.io/community/uploads/default/original/2X/9/9ce67a918ed86ca72fbfb078277c682c0951efdf.png "image")

and the balance is not returning how much Scroll Sepolia I have either.

---

<div class="post-metadata">

**Author:** ![w3abot](https://avatars.discourse-cdn.com/v4/letter/w/4da419/32.png) [@w3abot](https://builder.metamask.io/u/w3abot)\
**Post date:** [September 20, 2024, 3:46pm UTC](https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218/2 "2024-09-20T15:46:42Z")

</div>

Hi ENDER BOY,

Thanks for reaching out! It looks like you’re running into issues with the Web3Auth PnP Web SDK on the Scroll Sepolia network.

To help us diagnose the issue better, could you share:

1. The Web3Auth initialization and login code snippets.
2. Any browser console screenshots you might have that show the errors in detail.

This will help our team understand what’s going wrong and assist you more effectively.

This response was generated by the Web3Auth Bot and a member of our team will review and provide a more detailed answer shortly.

---

<div class="post-metadata">

**Author:** ![leeweixuan39](https://avatars.discourse-cdn.com/v4/letter/l/3da27b/32.png) [@leeweixuan39](https://builder.metamask.io/u/leeweixuan39)\
**Post date:** [September 20, 2024, 3:47pm UTC](https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218/3 "2024-09-20T15:47:24Z")

</div>

Hi, I’m just trying out the demo given by the docs

---

<div class="post-metadata">

**Author:** ![shahbaz](https://yyz1.discourse-cdn.com/flex011/user_avatar/builder.metamask.io/shahbaz/32/1527_2.png) [@shahbaz](https://builder.metamask.io/u/shahbaz)\
**Post date:** [September 24, 2024, 9:45am UTC](https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218/4 "2024-09-24T09:45:37Z")

</div>

Hey @leeweixuan39,

The demo you tried is using a feature that allows a developer to disable the export of the private key. And yes, we do support Scroll.

Please check again, I have disabled that flag.

---

<div class="post-metadata">

**Author:** ![leeweixuan39](https://avatars.discourse-cdn.com/v4/letter/l/3da27b/32.png) [@leeweixuan39](https://builder.metamask.io/u/leeweixuan39)\
**Post date:** [September 24, 2024, 3:34pm UTC](https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218/5 "2024-09-24T15:34:47Z")

</div>

Hi, thanks for the reply.

Unfortunately, when I tried again to get the private key, I’m getting the same error, although I have manually connected my network to Scroll Sepolia Network.

---

<div class="post-metadata">

**Author:** ![shahbaz](https://yyz1.discourse-cdn.com/flex011/user_avatar/builder.metamask.io/shahbaz/32/1527_2.png) [@shahbaz](https://builder.metamask.io/u/shahbaz)\
**Post date:** [September 25, 2024, 4:02am UTC](https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218/6 "2024-09-25T04:02:07Z")

</div>

Please share your code

---

<div class="post-metadata">

**Author:** ![leeweixuan39](https://avatars.discourse-cdn.com/v4/letter/l/3da27b/32.png) [@leeweixuan39](https://builder.metamask.io/u/leeweixuan39)\
**Post date:** [September 25, 2024, 4:41am UTC](https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218/7 "2024-09-25T04:41:07Z")

</div>

Hi, as mentioned above I’m just only trying out the EVM demo example in this page: : [https://evm-modal-example.vercel.app/](https://evm-modal-example.vercel.app/)

But I did tried to clone the repo, and this is my getPrivateKey function where I did not change any code within it:  
const getPrivateKey = async () =\> {  
if (!provider) {  
uiConsole(“provider not initialized yet”);  
return;  
}  
const rpc = new RPC(provider as IProvider);  
const privateKey = await rpc.getPrivateKey();  
uiConsole(privateKey);  
};

const uiConsole = (…args: any[]): void =\> {  
const el = document.querySelector(“#console\>p”);  
if (el) {  
el.innerHTML = JSON.stringify(args || {}, null, 2);  
}  
};

---

<div class="post-metadata">

**Author:** ![shahbaz](https://yyz1.discourse-cdn.com/flex011/user_avatar/builder.metamask.io/shahbaz/32/1527_2.png) [@shahbaz](https://builder.metamask.io/u/shahbaz)\
**Post date:** [September 25, 2024, 4:59am UTC](https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218/8 "2024-09-25T04:59:23Z")

</div>

> [@leeweixuan39](#):
>
> rpc.getPrivateKey()

And what does this code look like? same as [the code provided](https://github.com/Web3Auth/web3auth-pnp-examples/blob/main/web-modal-sdk/blockchain-connection-examples/evm-modal-example/src/viemRPC.ts#L95)?

Are you using your clientID in this project? or one provided in the example?

---

<div class="post-metadata">

**Author:** ![leeweixuan39](https://avatars.discourse-cdn.com/v4/letter/l/3da27b/32.png) [@leeweixuan39](https://builder.metamask.io/u/leeweixuan39)\
**Post date:** [September 25, 2024, 6:21am UTC](https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218/9 "2024-09-25T06:21:45Z")

</div>

Yes, it’s the same code as provided.

I have tried both using my own client ID (web3auth) and the clientID that is provided in the example.

I’m using walletconnect v2 project id.

---

<div class="post-metadata">

**Author:** ![leeweixuan39](https://avatars.discourse-cdn.com/v4/letter/l/3da27b/32.png) [@leeweixuan39](https://builder.metamask.io/u/leeweixuan39)\
**Post date:** [September 27, 2024, 7:29am UTC](https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218/10 "2024-09-27T07:29:32Z")

</div>

any updates on this?

---

<div class="post-metadata">

**Author:** ![maharshi](https://yyz1.discourse-cdn.com/flex011/user_avatar/builder.metamask.io/maharshi/32/1525_2.png) [@maharshi](https://builder.metamask.io/u/maharshi)\
**Post date:** [October 1, 2024, 7:00am UTC](https://builder.metamask.io/t/archive-does-web3auth-support-layer-2-network-scroll/1218/11 "2024-10-01T07:00:15Z")

</div>

Please share your chainConfig that you’ve passed as a parameter to the constructor?
