<p>The answer is Routing.
Define a wildcard route
e.g. URL/path/*
Then tell it to use a particular template if that route is used.</p>

<p>The key thing to do (which I didn't do first time around) is:
Don't duplicate the same route in a section.
If you do, Craft follows the section path not the routing path and expect entries to be in the CMS.</p>

CC BY-SA 4.0
2020-06-10T15:49:22.400Z
2020-06-10T15:49:22.400Z
Jonathan
<p>Can JSON feed data be displayed in a Craft site automatically?</p>

<p>I have a page: URL/asdfh3
I've been dynamically using 'asdfh3' to pull in data from the JSON feed that is associated with 'asdfh3'.
This template works - BUT ONLY if an entry for 'asdfh3' already exists in craft.</p>

<p>Whilst this can be achieved by running a feed update using the FeedMe plugin, it isn't a satisfactory method - as the site breaks if new data is entered into JSON without a feed update in Craft (no template found).</p>

<p>So, how can Craft display external content without having to set up entries for each piece of external content?</p>

<json>
Import JSON feed data automatically without FeedMe
# Import JSON feed data automatically without FeedMe

(Asked by: username_0 on 2020-06-10)

Can JSON feed data be displayed in a Craft site automatically?

I have a page: URL/asdfh3
I've been dynamically using 'asdfh3' to pull in data from the JSON feed that is associated with 'asdfh3'.
This template works - BUT ONLY if an entry for 'asdfh3' already exists in craft.

Whilst this can be achieved by running a feed update using the FeedMe plugin, it isn't a satisfactory method - as the site breaks if new data is entered into JSON without a feed update in Craft (no template found).

So, how can Craft display external content without having to set up entries for each piece of external content?

**Tags:** json

---

## 1 answers

### Answer by username_0 on 2020-06-10. Score: 1

The answer is Routing.
Define a wildcard route
e.g. URL/path/\*
Then tell it to use a particular template if that route is used.

The key thing to do (which I didn't do first time around) is:
Don't duplicate the same route in a section.
If you do, Craft follows the section path not the routing path and expect entries to be in the CMS.


---

