Meta Tag | Ceylon First
5/5 - (41 votes)

A meta tag is an HTML element that provides metadata about a web page. It is included in the head section of an HTML document and is not displayed on the actual page but provides information to browsers and search engine crawlers.

Meta tags play a crucial role in search engine optimisation (SEO) by helping search engines understand the content and context of a web page.

Here are some commonly used meta tags:

  1. Meta Description: This tag provides a brief summary or description of the page’s content. It often appears in search engine results below the page title and can influence click-through rates.

Example: <meta name="description" content="This is a description of my web page." />

  1. Meta Keywords: In the past, this tag was used to specify relevant keywords for search engines. However, most search engines now ignore this tag because of its susceptibility to keyword stuffing and spam.

Example: <meta name="keywords" content="keyword1, keyword2, keyword3" />

  1. Meta Title: This tag specifies the title of the web page. It is displayed as the clickable headline in search engine results and should be concise and descriptive.

Example: <title>My Web Page Title</title>

  1. Meta Robots: This tag informs search engine crawlers how to treat the page. It can indicate whether the page should be indexed, followed, or archived.

Example: <meta name="robots" content="index, follow" />

  1. Canonical Tag: This tag helps to prevent duplicate content issues by specifying the preferred URL for a page when multiple versions of the same content exist.

Example: <link rel="canonical" href="https://www.example.com/my-page" />

These are just a few examples of meta tags. There are various other meta tags available, each serving a specific purpose. Properly using meta tags can help improve the visibility and ranking of web pages in search engine results.

What is the use of meta tag with example?

Meta tags are HTML elements that provide metadata about a web page. They serve various purposes, such as providing information to browsers, search engine crawlers, and social media platforms.

Here are some common uses of meta tags with examples:

Meta Description:

  • Use: Provides a brief summary of the page’s content for search engine results.
  • Example: <meta name="description" content="Discover delicious recipes for homemade pizza." />

Meta Keywords:

  • Use: Previously used to specify relevant keywords for search engines, but now less influential.
  • Example: <meta name="keywords" content="pizza, homemade, recipe" />

Meta Title:

  • Use: Specifies the title of the web page, displayed as the headline in search engine results.
  • Example: <title>Homemade Pizza Recipes - Delicious and Easy</title>

Meta Robots:

  • Use: Informs search engine crawlers how to handle the page (index, follow, noindex, nofollow).
  • Example: <meta name="robots" content="index, follow" />

Canonical Tag:

  • Use: Prevents duplicate content issues by specifying the preferred URL for a page.
  • Example: <link rel="canonical" href="https://www.example.com/homemade-pizza" />

Open Graph Protocol (OGP) Tags:

  • Use: Provides structured data to social media platforms for sharing web page information.
  • Example:
    <meta property="og:title" content="Homemade Pizza Recipes" /> <meta property="og:description" content="Discover delicious recipes for homemade pizza." /> <meta property="og:image" content="https://www.example.com/images/pizza.jpg" />

Twitter Card Tags:

  • Use: Similar to OGP tags, but specifically for sharing on Twitter.
  • Example:
    <meta name="twitter:card" content="summary_large_image" /> <meta name="twitter:title" content="Homemade Pizza Recipes" /> <meta name="twitter:description" content="Discover delicious recipes for homemade pizza." /> <meta name="twitter:image" content="https://www.example.com/images/pizza.jpg" />

These are just a few examples of meta tags and their uses. Different meta tags serve different purposes and can provide valuable information to improve the visibility, indexing, and presentation of web pages across various platforms.

How do you add a meta tag?

To add a meta tag to your web page, you need to insert the appropriate HTML code within the <head> section of your HTML document.

Here’s a step-by-step guide on how to add a meta tag:

  1. Open the HTML file of your web page using a text editor or an integrated development environment (IDE).
  2. Locate the <head> section of your HTML document. It is typically placed between the <html> opening tag and the <body> opening tag.
  3. Decide which meta tag you want to add and choose the appropriate HTML tag and attributes based on its purpose. Here are a few examples:
  • Meta Description: <meta name="description" content="Your description goes here" />
  • Meta Keywords: <meta name="keywords" content="keyword1, keyword2, keyword3" />
  • Meta Title: <title>Your Page Title</title>
  • Meta Robots: <meta name="robots" content="index, follow" />
  • Canonical Tag:
    html <link rel="canonical" href="https://www.example.com/your-page" />

Insert the desired meta tag code within the <head> section.

For example, if you want to add a meta description, you would place the following code between the opening and closing <head> tags:

   <head>
     <!-- Other meta tags, stylesheets, etc. -->
     <meta name="description" content="Your description goes here" />
   </head>

Save the changes to your HTML file.

After adding the meta tag, it will be recognised by browsers, search engine crawlers, or social media platforms, depending on its purpose. Remember to ensure that the meta tags are properly formatted with correct attribute values to ensure their effectiveness.

How do I set meta tags for SEO?

Setting meta tags for SEO (Search Engine Optimisation) involves optimizing your web page’s metadata to improve its visibility and relevance in search engine results.

Here are some guidelines to help you set meta tags for SEO:

Meta Title:

  • Keep it concise and descriptive, ideally within 50-60 characters.
  • Include relevant keywords that accurately represent the page’s content.
  • Make each page’s title unique to avoid confusion and duplication.

Meta Description:

  • Write a compelling and concise description that accurately summarizes the page’s content.
  • Aim for a length of around 150-160 characters.
  • Include relevant keywords but avoid excessive keyword stuffing.
  • Make each page’s description unique and engaging to encourage click-throughs.

Meta Keywords:

  • Many search engines no longer consider this tag for ranking purposes.
  • However, if you still want to include it, choose relevant keywords that reflect the page’s content.
  • Avoid excessive repetition and irrelevant or unrelated keywords.

Canonical Tag:

  • Use the canonical tag to address duplicate content issues.
  • Set the canonical tag to the preferred URL version of your page.
  • This helps search engines understand which version of the page should be indexed and displayed in search results.

Open Graph Protocol (OGP) Tags:

  • Use OGP tags to optimize how your content appears when shared on social media platforms like Facebook, LinkedIn, or Twitter.
  • Include tags such as title, description, image, and URL to ensure visually appealing and accurate social media previews.

Structured Data:

  • Consider adding structured data markup (e.g., Schema.org) to provide search engines with more detailed information about your content.
  • Structured data helps search engines better understand and present your content, potentially leading to enhanced search result displays (rich snippets).

Remember, setting meta tags is just one aspect of SEO. Additionally, focus on creating high-quality, relevant content, optimizing your website’s performance and speed, building quality backlinks, and providing a positive user experience. SEO involves a holistic approach to improve your website’s visibility and rankings in search engine results.

How do meta tags work?

The main purpose of a meta tag is to provide metadata about a web page. Meta tags contain information that describes the page’s content, structure, and other attributes.

Here are the main purposes of meta tags:

  1. Search Engine Optimisation (SEO): Meta tags play a crucial role in SEO by providing information to search engines about the content and relevance of a web page. Search engine crawlers analyze meta tags to understand the page’s topic, keywords, and other details, which can impact the page’s ranking and visibility in search engine results.
  2. Search Engine Result Pages (SERPs): Meta tags can influence how a web page appears in search engine result pages. The meta title and meta description tags often appear as the page’s title and snippet in search results. Well-crafted meta tags can attract users and increase click-through rates.
  3. Website Display and Rendering: Meta tags provide instructions to web browsers on how to display and render the web page. They can specify the character encoding, viewport settings for responsive design, CSS stylesheets, and other details that affect the page’s appearance and functionality.
  4. Social Media Sharing: Meta tags like Open Graph Protocol (OGP) tags and Twitter Card tags provide structured data to social media platforms when a web page is shared. They control how the page’s title, description, image, and URL appear in social media posts, ensuring visually appealing and accurate previews.
  5. Crawling and Indexing: Search engine crawlers rely on meta tags, such as the meta robots tag and canonical tag, to understand how to crawl and index a web page. These tags can instruct search engines to index or exclude pages, follow or nofollow links, and consolidate duplicate content under a preferred canonical URL.
  6. Accessibility and Usability: Meta tags can provide accessibility-related information, such as specifying language attributes or indicating alternative versions of the page (e.g., mobile or print versions). They contribute to creating a more accessible and user-friendly browsing experience.

Overall, meta tags serve as a way to communicate important information about a web page to browsers, search engines, and other applications. They play a significant role in optimizing search engine visibility, enhancing website presentation, and improving user experience.

What are meta tags for beginners?

For beginners, meta tags may seem overwhelming at first, but they are relatively simple HTML elements that provide metadata about a web page.

Here are some key meta tags that beginners should be familiar with:

Meta Title:

  • Purpose: Specifies the title of the web page.
  • Example: <title>My Web Page Title</title>
  • Tips: Keep it concise, descriptive, and unique for each page.

Meta Description:

  • Purpose: Provides a brief summary of the page’s content.
  • Example: <meta name="description" content="This is a description of my web page." />
  • Tips: Write an engaging description within 150-160 characters. Make it unique for each page.

Meta Keywords:

  • Purpose: Specifies relevant keywords for search engines (now less influential).
  • Example: <meta name="keywords" content="keyword1, keyword2, keyword3" />
  • Tips: Choose relevant keywords, but avoid excessive repetition or irrelevant keywords.

Meta Robots:

  • Purpose: Instructs search engine crawlers how to treat the page.
  • Example: <meta name="robots" content="index, follow" />
  • Tips: Use “index” to allow indexing, “follow” to follow links, or “noindex” and “nofollow” to exclude the page from indexing or following links.

Canonical Tag:

  • Purpose: Helps prevent duplicate content issues by specifying the preferred URL for a page.
  • Example: <link rel="canonical" href="https://www.example.com/my-page" />
  • Tips: Set the canonical URL to the preferred version of the page when duplicate content exists.

By understanding and utilising these basic meta tags, beginners can improve their web page’s visibility, search engine ranking, and overall user experience. It’s important to learn more about meta tags and their specific uses as you progress in web development and search engine optimisation.

CEYLON FIRST

About Author

Leave feedback about this

  • Rating