GitHub repository not listing in Google search [closed]
Asked Answered
S

4

47

I created my first repository with GitHub but when I try to google it, its not listing RoboSpice-Extn-Retrofit-Tutorial

EDIT

I don't know how long it will take. On the other hand anyone can take a help of Google Webmaster, this would solve your problem in minutes :)

Sawn answered 5/10, 2014 at 4:48 Comment(8)
can you please tell me how did you add your repository to google search engine and verified it?Collision
@MrJSingh I didn't add repository to search engine manuallySawn
But you mentioned that you used Web master tools?Collision
Yes , we should also use Webmaster. Are you finding any difficulty on using it?Sawn
Yes when I add github repo to Web master then it want to verify and there I'm stuck.Collision
@MrJSingh As I remembered after adding to Webmaster my one is start listingSawn
Ok i don't know what's changed since that but it clearly asking for validation and it's unable to validate my repo there. I guess I need to dig more deep in webmaster 😪Collision
I’m voting to close this question because this is actually a SEO question which is off topic. What topics can I ask about here?Boxthorn
F
35

That repo seems to have been created less than an hour ago.
Give Google a little time to parse the new repos, and it should show up.

Note that it is referenced by GitHub search already:

https://github.com/search?utf8=%E2%9C%93&q=RoboSpice-Extn-Retrofit-Tutorial

As the OP used the Webmaster Tools to submit its url, the repo is now indexed in Google.


Update 2019: the section "Enabling GitHub Pages to publish your site from master or gh-pages" is now (since 2014) more precise:

To select master or gh-pages as your publishing source, you must have the branch present in your repository.
If you don't have a master or gh-pages branch, you can create them and then return to source settings to change your publishing source.

Once the correct branch is created/populated, and selected as the publishing source, the Google indexing seems to be very quick.

Feast answered 5/10, 2014 at 4:59 Comment(8)
Thanks but what about github.io pages? My post months before cannot be get from google.Indigestive
@SummerSun It should be indexed unless you are using a domain of your own with a robots.txt: https://mcmap.net/q/372693/-stopping-index-of-github-pagesFeast
I created Repository "ArmoredDeathmatch" 4 years ago. I am not able to find it using google search. Only search box on github.com can find it.Keystroke
Is there a way to disable the indexing of Google, Bing, DuckDuckGo for a GitHub page?Mastership
@Mastership I answered in 2015 about robot.txt (https://mcmap.net/q/372693/-stopping-index-of-github-pages), but the other answer about meta directive (https://mcmap.net/q/372693/-stopping-index-of-github-pages) is more up-to-date.Feast
In my case, after 3 months nothing shows up on google.Sender
@Sender What is your publication source? You might get more from an independent question here, with a reference back to this answer, and detailing your current setup.Feast
@Feast , I followed the guide about GitHub Pages in your comment just now. I'll come back later, thanx.Sender
B
19

This is how I managed to get at least my github pages-page to be found on Google:

  1. go to google search console https://search.google.com/search-console/
  2. add new "property" with "URL prefix" as suggested
  3. add the meta tag on your github-pages site (html-head) as described, looks like <meta name="google-site-verification" content="...">
  4. paste your page URL to the "search bar" on the top of the search console and press <Enter>. Important: use full path to page, including the .html page, e.g. https://<user>.github.io/<your repo>/demo/index.html
  5. Click on "request indexing"

I first only did points 1-3 with the URL https://<user>.github.io/<my-repo>/demo/ and the page still did not show up after waiting for a month. However after doing points (4) and (5) my github-pages site immediately showed up in the Google search results.

edit: one day later also the github repository showed up on Google search (but maybe only because I link the original repository in my github-pages site).

Boyar answered 22/7, 2019 at 9:1 Comment(5)
Which URL are you using in Step 2? In Step 2 are you using the URL for your GitHub Page or the URL for the gh-pages branch of your GitHub repository or the URL shown in your Step 4 or the URL that appears when you first access your GitHub repository (without /tree/gh-pages or /tree/main at the end)? I can find no search bar at the top of Google Search Console mentioned in Step 4. I can find no way to request indexing mentioned in Step 5. I see a Verify button. But when I click that button I get a message that the meta tag is incorrect.Chambless
As stated in my answer: use the URL of your Github Page like https://<user>.github.io/<my-repo>/demo/ for steps 1-3. The search bar on the top looks like this: i.imgur.com/iZQd6qP.pngBoyar
The search bar mentioned in Step 4 only appears if site verification is successful in Step 3. That search bar is not visible prior to Step 4. The URL shown in Step 4 is very confusing because it is combining the URL for the GitHub Page with the index.html file from the GitHub repository. When I press Enter in Step 4 I get a message that "Something went wrong" no matter what URL I paste into the search bar. Perhaps I need to wait a day or more before I can complete Step 4. You mentioned that a month passed before you completed Step 4.Chambless
On Github Page you have the same files as in your GitHub repository (gh-pages branch or also main/master, depending on configuration), but hosted on a webserver, so I don't think it's confusing. The url https://<user>.github.io/<your repo>/demo/index.html is just an example, if you don't have index.html or folder demo in your repo (gh-pages, master/main) branch, it won't work, you have to use a file existing in your repo.Boyar
After posting my last comment I discovered that the GitHub Page can be displayed with or without index.html at the end of its URL. I still got an error in Step 4 when I pressed Enter. I had to wait ~48 hours before I could complete Step 4. Then I requested indexing as in Step 5. I got a message that the URL is not on Google. Maybe I need to wait another day or two for Google to index the site to complete Step 5.Chambless
S
5

When GitHub auto-generate your page, you get only the _config.yml file and not the html files. So if you want to keep the default page and not write html yourself, you have to:

  • Find the original template from the theme's repository, for the slate theme the template is https://github.com/pages-themes/slate/blob/master/_layouts/default.html
  • Create a folder named _layout
  • Create a file called _layouts/default.html
  • In the default.html copy and paste the contents of the template
  • Follow klues post and generate your <meta name="google-site-verification" content="..."> tag
  • Add the meta tag to default.html
Sordino answered 14/9, 2019 at 17:28 Comment(1)
This was the answer I was looking for! Thank you so much!Fake
P
2

If you give some time to Google it will reflect in google search
Make sure to use better key words in your github ReadMe and title,tags of repo to make it more visible See this for an Example: https://github.com/anupama513/Tk102-gps-data-parser-nodejs-server

Parthen answered 20/7, 2017 at 4:3 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.