# IncludeRefs not working

**URL:** <https://forum.builder.io/t/includerefs-not-working/4463>\
**Category:** Technical Questions\
**Tags:** visual-editor\
**Created:** [November 15, 2023, 4:58pm UTC](https://forum.builder.io/t/includerefs-not-working/4463 "2023-11-15T16:58:48Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![CourseStudio](https://avatars.discourse-cdn.com/v4/letter/c/838e76/32.png) [@CourseStudio](https://forum.builder.io/u/CourseStudio)\
**Post date:** [November 15, 2023, 4:58pm UTC](https://forum.builder.io/t/includerefs-not-working/4463/1 "2023-11-15T16:58:48Z")

</div>

We’ve tried both `includeRefs` and `enrich` to get Builder to include the content from references but with no luck. References that are set up via the code seems to work but not those that are set in the [Builder.io](http://Builder.io) models.

**Builder content link**

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

**Builder public api key**  
4ccc9312e0d14fb3b6d94d2864010b90

**What are you trying to accomplish**  
Use the _reference_ input type and have the results include the value of the reference in the `<BuilderComponent />`

**Screenshots or video link**  
 ![Screenshot 2023-11-15 at 08.56.52](https://us1.discourse-cdn.com/flex020/uploads/builder/original/2X/9/932be16bf64139fee442e025abffb6a9c46d5153.png)

**Code stack you are integrating Builder with**  
NextJS

**Reproducible code example**

```auto
<BuilderComponent
          options={{ includeRefs: true, enrich: true }}
          content={content}
          model="page"
        />

```

And

```auto
.get("page", {
      includeRefs: true,
      enrich: true,
      userAttributes: {
        urlPath,
      },
    })
    .toPromise();

```

---

<div class="post-metadata">

**Author:** ![manish-sharma](https://avatars.discourse-cdn.com/v4/letter/m/8797f3/32.png) [@manish-sharma](https://forum.builder.io/u/manish-sharma)\
**Post date:** [November 16, 2023, 6:01am UTC](https://forum.builder.io/t/includerefs-not-working/4463/2 "2023-11-16T06:01:20Z")

</div>

Hello @CourseStudio,

Although the reference data may not be visible in the UI, you can check for it in the Builder console. Select the block, go to the builder console, navigate to the data tab, and run `$block.eval('state')`. This should allow you to access the data even if it’s not displaying in the UI.

 ![Screenshot 2023-11-16 at 11.24.23 AM](https://us1.discourse-cdn.com/flex020/uploads/builder/original/2X/d/d43d4670d15c517ad3d809635433d38c09f3e443.png)

loom: [Loom | Free Screen & Video Recording Software | Loom](https://www.loom.com/share/b6898b576c9e420b8883e7752740071c?sid=4c317d13-edb3-4ff9-88c5-24a0877db8dc)

Thank you,

---

<div class="post-metadata">

**Author:** ![CourseStudio](https://avatars.discourse-cdn.com/v4/letter/c/838e76/32.png) [@CourseStudio](https://forum.builder.io/u/CourseStudio)\
**Post date:** [December 6, 2023, 5:33pm UTC](https://forum.builder.io/t/includerefs-not-working/4463/3 "2023-12-06T17:33:09Z")

</div>

Hi Manish

How can I get this to work in the code?

---

<div class="post-metadata">

**Author:** ![manish-sharma](https://avatars.discourse-cdn.com/v4/letter/m/8797f3/32.png) [@manish-sharma](https://forum.builder.io/u/manish-sharma)\
**Post date:** [December 8, 2023, 12:28pm UTC](https://forum.builder.io/t/includerefs-not-working/4463/4 "2023-12-08T12:28:29Z")

</div>

Hello @CourseStudio,

could you please provide more information about what you meant by “getting this work in the code”?

---

<div class="post-metadata">

**Author:** ![wtc-marlonmarcello](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.builder.io/wtc-marlonmarcello/32/3205_2.png) [@wtc-marlonmarcello](https://forum.builder.io/u/wtc-marlonmarcello)\
**Post date:** [December 11, 2023, 10:03am UTC](https://forum.builder.io/t/includerefs-not-working/4463/5 "2023-12-11T10:03:02Z")

</div>

Having the same issue
