What is the purpose of the 'robots.txt' file on a website? MCQ with Answer and Explanation

What is the purpose of the 'robots.txt' file on a website?
A. To configure the web server
B. To instruct search engine crawlers which parts of the site to index
C. To store user login credentials
D. To block malicious users
Answer: Option B
Solution (By JKSSB Mock Tests)
The robots.txt file is a standard used by websites to communicate with web crawlers, indicating which pages or sections should not be crawled or indexed.

Discuss this Question (0)

No comments yet. Be the first to start the discussion!

Practice More Internet and Web Technologies Questions

Question #1
What mechanism does a web server implement to gracefully instruct a browser that an old web resource has changed its location permanently to a new URL address asset?
A. Setting a temporary session tracking cookie inside memory
B. Issuing a general 500 Internal Error crash notification alert
C. Issuing an HTTP 301 Moved Permanently response code with the new location header
D. Altering the local computer DNS router configurations

Correct Answer: Option C


Explanation:
An HTTP 301 redirect informs browsers and search engines that a page has permanently relocated, prompting them to update their links and pass SEO ranking history to the new URL.

This question belongs to: Computer Internet and Web Technologies
Question #2
What type of cookies are discarded automatically from your local browser once you close your active browser window or terminate your session?
A. First-Party Analytical Cookies
B. Third-Party Tracking Cookies
C. Persistent Cookies
D. Session Cookies

Correct Answer: Option D


Explanation:
Session cookies only exist in temporary volatile memory while the user navigates the site and are wiped upon closing the browser application.

This question belongs to: Computer Internet and Web Technologies
Question #3
What is the purpose of a URL encoding?
A. To compress the URL
B. To convert unsafe characters into a safe format
C. To hide the URL from search engines
D. To make the URL shorter

Correct Answer: Option B


Explanation:
URL encoding (percent-encoding) replaces unsafe ASCII characters with a '%' followed by two hexadecimal digits to ensure the URL is valid and transmitted correctly.

This question belongs to: Computer Internet and Web Technologies