'How to add Instagram feed using HTML or Javascript

So I'm trying to add an actual Instagram feed to my wordpress site. I dont want to use a 3rd party site which doesnt drive traffic to the actual IG site. I've been on the IG developers site and to be honest kind of confusing. Any help would be greatly appreciated.



Solution 1:[1]

I would recommend using a plugin to do the hard work, since there are many out there, and integrating the instagram yourself could be a challenge. A quick google search gave me this one: https://wordpress.org/plugins/instagram-feed/

If you don't want to use a plugin, you need to understand how the api works.

The instagram API requires OAuth authentication for most calls. First, You will need to register an application on the https://instagram.com/developer/ site in order to obtain a client Id.

Once you have a client Id, you need to establish a flow for users who visit your site. There is no way around this for API calls requiring authentication.

First, the user needs to login and allow access from your account using the instagram api request url: https://api.instagram.com/oauth/authorize/?client_id=CLIENT-ID&redirect_uri=REDIRECT-URI&response_type=code

CLIENT-ID is the id you obtained earlier, and REDIRECT-URL should be your wordpress site. Calling this url will allow you to obtain an access token for the user on your site, and you can then make authenticated calls to the API using that token.

One way around this is to make simple calls that don't require authentication, using tags that are specific to your photos. That is described in this SO question: Instagram API and importing photos without server side authentication

Solution 2:[2]

Cheers, I agree with Felipe. If you or your client need an Instagram plugin, the easiest way would be to buy it at some marketplace. What’s more important, it is much cheaper than wasting your own time on developing one. Of course, that applies to commercial development, not something that you do for fun.

Here’s a list of plugins that I’ve installed to my clients and was happy about:

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Community
Solution 2 Andrew Kozinskii