Moralis SDK AppId exposed

Hi… I use php for backend and html/javascript for frontend. Which is the best way to use sdk moralis login without exposed appId and serverUrl in html file?

const serverUrl = “https://xxx.usemoralis.com:2053/server”;
const appId = “xxx”;
Moralis.start({ serverUrl, appId });

Thanks

you dont hide it https://docs.moralis.io/misc/faq#my-moralis-app-id-is-publicly-visible-on-the-frontend.-is-this-a-security-risk

Great! Thank you so much ivan!

2 Likes