Add Image to GitHub Readme.md from Google Drive

GokulDAS027 picture GokulDAS027 · Aug 28, 2018 · Viewed 8.4k times · Source

I have the image in Drive, How could it be added to the Readme.md so as to display the image in readme. I had tried with the shared link, but it isn't working.

Answer

Echan picture Echan · Nov 14, 2018

For example, I have a.jpg on the google drive.

  1. Right click the image and click Share...

  2. Click Advanced and change the Who can access option to Public on the web - Anyone on the Internet

  3. Copy the link to share and you will have something like

    https://drive.google.com/file/d/<FILE_ID>/view?usp=sharing

  4. Copy the <FILE_ID> to make a link like this:

    https://drive.google.com/uc?export=view&id=<FILE_ID>

  5. Insert image in Markdown as ususal using the link from step 4.
    For example: ![image](https://drive.google.com/uc?export=view&id=<FILE_ID>)

Example: I have this octocat image in google, and its file id is 1913oZeBZPBNiUuk8gu3ZSbLBA2l_VQtG. You can try ![image](https://drive.google.com/uc?export=view&id=1913oZeBZPBNiUuk8gu3ZSbLBA2l_VQtG) in your markdown file or even in this answer.

image

Hope this helps.