# Empty url for preview not working on homepage

**URL:** <https://forum.builder.io/t/empty-url-for-preview-not-working-on-homepage/4425>\
**Category:** Technical Questions\
**Tags:** visual-editor, nextjs\
**Created:** [November 8, 2023, 7:42am UTC](https://forum.builder.io/t/empty-url-for-preview-not-working-on-homepage/4425 "2023-11-08T07:42:44Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![gamersensei](https://avatars.discourse-cdn.com/v4/letter/g/f6c823/32.png) [@gamersensei](https://forum.builder.io/u/gamersensei)\
**Post date:** [November 8, 2023, 7:42am UTC](https://forum.builder.io/t/empty-url-for-preview-not-working-on-homepage/4425/1 "2023-11-08T07:42:44Z")

</div>

Hi,  
I am trying to access the home page with the “[http://localhost:3000/](http://localhost:3000/)” URL  
but I am not able to use this URL in the visual editor  
I am getting the preview load error  
I followed the instructions from docs but that isn’t working

**Builder content link**

> **[Builder.io: Drag & Drop Headless CMS](https://builder.io/content/bb34833661084eacb38f6da1283e422f)**
>
> Drag and drop with your components, right within your existing site or app. Build and optimize digital experiences for any tech stack, visually..

 ![Capture.PNG](https://us1.discourse-cdn.com/flex020/uploads/builder/original/2X/9/96ea30f2f0441f823ba3c4dfece22e60e171466e.jpeg)  
 ![home.PNG](https://us1.discourse-cdn.com/flex020/uploads/builder/original/2X/1/19c54ea1dc648f8c2edf3a5ece4e44d54870f8fb.jpeg)

---

<div class="post-metadata">

**Author:** ![sheema](https://avatars.discourse-cdn.com/v4/letter/s/e19adc/32.png) [@sheema](https://forum.builder.io/u/sheema)\
**Post date:** [November 8, 2023, 10:22am UTC](https://forum.builder.io/t/empty-url-for-preview-not-working-on-homepage/4425/2 "2023-11-08T10:22:45Z")

</div>

Hey @gamersensei What is the Tech stack you are using? The error might be caused because of your folder structure. Follow our [Quickstart Guide](https://www.builder.io/c/docs/quickstart) to make sure you are routing the pages correctly.

---

<div class="post-metadata">

**Author:** ![gamersensei](https://avatars.discourse-cdn.com/v4/letter/g/f6c823/32.png) [@gamersensei](https://forum.builder.io/u/gamersensei)\
**Post date:** [November 8, 2023, 10:34am UTC](https://forum.builder.io/t/empty-url-for-preview-not-working-on-homepage/4425/3 "2023-11-08T10:34:58Z")

</div>

hi @sheema ,  
i am using next js , i did install it following the quick start guide

---

<div class="post-metadata">

**Author:** ![sheema](https://avatars.discourse-cdn.com/v4/letter/s/e19adc/32.png) [@sheema](https://forum.builder.io/u/sheema)\
**Post date:** [November 8, 2023, 11:03am UTC](https://forum.builder.io/t/empty-url-for-preview-not-working-on-homepage/4425/4 "2023-11-08T11:03:15Z")

</div>

The Quickstart Guide changes the folder structure which can cause an issue when loading the home page. You need to make sure you are following the app structure provided in the guide.

Paste the following code into a new file within the `pages` directory called `[...page].tsx` (you must include the brackets and ellipses), making sure to replace `YOUR_API_KEY` with your [Public API Key](https://www.builder.io/c/docs/using-your-api-key), which you can find in the [Account](https://builder.io/account/space) section of Builder.

**Tip:** If you don’t have a `pages` directory, be sure to create one. Or, if you prefer to use the App Router instead, see the [guide for integrating the Next.js App Router](https://www.builder.io/c/docs/quickstart?codeFramework=nextApp).

**Tip:** If you don’t have an index route, such as `pages/index.tsx` , use `pages/[[...page.tsx]]` with two sets of square brackets. The two square brackets means that Builder handles the app’s home page.

The single set of square brackets, in this tutorial, assumes that you _are_ keeping your home page.

Alternatively, you can checkout our github repo [https://github.com/BuilderIO/builder/tree/main/examples/next-js-simple](https://github.com/BuilderIO/builder/tree/main/examples/next-js-simple).  
You wouldn’t need to change the folder structure in this one. Your folder structure should look like this

 ![Screenshot 2023-11-08 at 4.29.32 PM](https://us1.discourse-cdn.com/flex020/uploads/builder/original/2X/2/207347e299a6eb6cd16acc72fa4b01e4ee1eba5b.png)

---

<div class="post-metadata">

**Author:** ![gamersensei](https://avatars.discourse-cdn.com/v4/letter/g/f6c823/32.png) [@gamersensei](https://forum.builder.io/u/gamersensei)\
**Post date:** [November 8, 2023, 2:36pm UTC](https://forum.builder.io/t/empty-url-for-preview-not-working-on-homepage/4425/5 "2023-11-08T14:36:08Z")

</div>

i do have the similar structure with index.tsx  
 ![folders](https://us1.discourse-cdn.com/flex020/uploads/builder/original/2X/2/242cf3e3e66bba3eaf25ffb1d1bf5a9ca5c8707a.png)

---

<div class="post-metadata">

**Author:** ![gamersensei](https://avatars.discourse-cdn.com/v4/letter/g/f6c823/32.png) [@gamersensei](https://forum.builder.io/u/gamersensei)\
**Post date:** [November 9, 2023, 4:18am UTC](https://forum.builder.io/t/empty-url-for-preview-not-working-on-homepage/4425/6 "2023-11-09T04:18:56Z")

</div>

@sheema thanks for the help changing the component in index.tsx worked
