wordpress agency, wordpress agency for development, enterprise wordpress, wordpress website, wordpress developer, make a website, wordpress sites, wordpress blog, wordpress for dummies, wordpress website development, wordpress website design, wordpress design, wordpress web design, wordpress help, wordpress designer, premium wordpress themes, create a wordpress website, wordpress plugin development, wordpress theme development, build a wordpress website, wordpress website templates, wordpress web, woocommerce plugin, wordpress free website, wp themes, setting up a website, wordpress web development, wordpress homepage, wordpress cms, best wordpress sites, custom wordpress theme, wordpress for beginners, best wordpress websites, using wordpress, wordpress designs, create website using wordpress, wordpress web developer, wordpress website hosting, wordpress website examples, create new website, start a website, wordpress premium, wordpress web hosting, create wordpress, wordpress customization, wordpress plugin developer, create wordpress theme, custom wordpress development, wordpress guide, wordpress programming, wordpress design services, create wordpress blog, wordpress website tutorial, using wordpress to build a website, how to build a wordpress website, wordpress website developer, using wordpress to create a website, custom wordpress design, wordpress website designers, building a website from scratch, online site hosted by wordpress, wordpress website development company, hosted wordpress, i want to create a website, best wordpress, build website using wordpress, woocommerce wordpress, website using wordpress, make a wordpress website, setting up a wordpress site, start a wordpress blog, wordpress web design company, wordpress website development services, buy wordpress themes, custom wordpress, create wordpress site, wordpress web design services, wordpress themes for business, wordpress page, world press website, custom wordpress website, steps to create a website, websites created with wordpress, best way to create a website, wordpress web design for dummies, wordpress website design company, learn wordpress step by step, build wordpress site, building a website for dummies, using wordpress for a website, create a website from scratch, wordpress website themes, website design using wordpress, wordpress business website, best way to build a website, design wordpress theme, wordpress site design, wordpress professional, wordpress blog page, wordpress site development, how to create a website with wordpress, top wordpress sites, make a website from scratch, make a webpage, build your own wordpress website, setting up a wordpress blog, get wordpress, wordpress layouts, building a website, wordpress website design tutorial, wordpress free site, website creation, e commerce website, website design, create wordpress account, wordpress web development services, design a website, wordpress cms tutorial, setting up your own website, create your own website wordpress, website developer, website developers, best premium wordpress themes, wordpress free blog, top wordpress websites, create a blog website, build wordpress theme, webdesign, website design companies, best way to make a website, web agency, web developers, custom wordpress plugin development, web page design, wordpress malware, web design companies, ecommerce website design, designer websites, professional website design, wordpress best themes, wordpress create website free, professional website, custom wordpress website design, wordpress blog examples, wp plugin development, examples of wordpress sites, web development companies, web design agency, wordpress webpage, custom website design, mobile website design, best way to learn wordpress, web development agency, popular wordpress blogs, setting up a wordpress website, ecommerce web design, create your own wordpress theme, custom web design, ecommerce website development, wordpress web design theme, build your own wordpress site, website companies, website design agency, website development company, wordpress for business, web application development, best wordpress designers, custom website, web design tools, professional web design, web creation, design companies, web design studio, web development websites, new wordpress, ecommerce design, how to use wordpress to create a website, website design and development, wordpress website management, wordpress start, make a wordpress site, wordpress membership plugin, new wordpress website, web design and development, make wordpress, custom wordpress site, the best wordpress themes, ecommerce web development, wordpress application development, great wordpress sites, wordpress theme designer, new website design, wordpress step by step, web design portfolio, develop website using wordpress, create professional website, best web design, online wordpress, new wordpress site, wordpress tutorials for beginners, best web design company, create wordpress template, start wordpress website, themes wordpress, world press website design, build your website with wordpress, best wordpress blogs, learn to build a website, wordpress tutorial 2022, woocommerce shop, web design prices, premium wp themes, ecommerce website development company

WordPress Agency for Development | Vipe Studio » WordPress Development » A Guide to Shortlinks for WordPress

A Guide to Shortlinks for WordPress

Reading Time: 4 minutes

Remember that time when that link you were trying to post on social media overshadowed the post itself, or you ran out of characters? And even if that didn’t happen, maybe the alphabet (and number and symbol) soup in the link string just didn’t go with the look you had in mind?

Sounds like you are (and were) in the market for shortlinks!

True to their name, shortlinks are shorter versions of links (URLs) that, when clicked, point to the actual (long, unwieldy) URL for the page.

Why Do You Even Need Shortlinks with WordPress?

Well, we did look at a couple of use cases up there, but here’s a more comprehensive set of reasons for choosing the shortlink life:

  • Character Counts and Simplification
  • Aesthetics
  • Analytics

Character Counts and Simplification – Let’s get the obvious one out of the way – yes, every time you have a Twitter post or tiny text box situation, the trusty shortlink has you covered. The URL gets put in its comfy space, and your text can really shine.

Aesthetics – Shortlinks are quite a bit easier on the eye. They look tidy, reliable and manageable, particularly when the original URL looks like a mess. Add to that the convenience of putting your brand front and center with custom shortlinks, and it’s obvious why you need them.

  Top 5 WordPress themes for culinary blogs

Analytics – If you’d like to track metrics like numbers, dates and times of clicks or client devices used, a lot of link shorteners will let you do just that. You can of course use Google Analytics to achieve the same result, but it never hurts to have multiple sets of digital eyes on your data.

Disclaimer, though: A shortlink isn’t a cure-all. Sometimes the page preview that a full URL can provide brings more value (and clicks) to the table. Feel free to try out both and see what works for your specific needs.

Creating Shortlinks in WordPress

Bitly and all the other third party link-shorteners are all over the internet landscape, but we can get our own shortlinks made from right inside WordPress.

WordPress versions before 4.4 had a button to create and assign a shortlink to the page in question. The good news is that we can bring that button back with just a little code. Read on:

The code itself.

This part is pretty easy because the code is still present in WordPress’s files, just not visible in the editor. A quick and easy filter will fix this, and the ‘Get Shortlink’ button should be visible:

add_filter( 'get_shortlink', function( $shortlink ) {return $shortlink;} );

Adding it to the theme.

Head over to the WordPress dashboard, and find the ‘Theme Editor’ under ‘Appearance’. In the ‘Edit Themes’ screen that pops up, the list on the right will contain the functions.php file, usually named ‘Theme Functions’. Here, at the bottom of this file, you can add on the above code hook. Choose ‘Update File’ to finish.

  How to Use Visual Elements to Enhance the Engagement in Your Blog Post

Checking whether the code works.

If we did everything as described, there should now be a ‘Get Shortlink’ button in the Classic Editor view of posts, next to the post name. Clicking on the button will provide you with the shortlink and you can copy it.

Using a Plugin for Shortlinks

Remember we said that the button would show up in the ‘Classic Editor’ view? That’s because it doesn’t show up in the ‘Block Editor’ view, and we’ll need a plugin to get that done. Luckily, while there’s more than one plugin that does this, we’ve picked the popular and convenient Pretty Links plugin for our purposes. Here’s how to use it:

  1. Installation. On the WordPress dashboard, select ‘Plugins’, and choose ‘Add New’. Search for ‘Pretty Links’, install and activate it.
  2. Create the Shortlink.
    • Find ‘Pretty Links’ on your sidebar, and follow it to its own dashboard, which displays all the shortlinks you’ve created.
    • Choose ‘Add New’, enter the original URL, and edit the URL slug for your shortlink – the slug being the part of the URL that’s right after the domain name.
    • In the ‘Advanced’ tab, there are options like setting the link to be ‘sponsored’, activating tracking or parameter forwarding, and marking the link ‘nofollow’.

Your new shortlink will be visible in the Pretty Links dashboard, with options, edits possible, and the choice to share it via Twitter and email. Pretty Links Pro adds some features, but you won’t need them if you’re just after shortlinks.

  Vipe Studio Gives Away a Ticket for WordCamp Europe 2022

And that wraps it up for this overview on Shortlinks for WordPress. We’ll see you next time with more WordPress tips!

Looking for WordPress Website Development for your Business?

Our professional developers have proven experience in building high-quality business websites that outperform the competition, thanks to our meticulous attention to detail and the implementation of cutting-edge technologies. We will conduct an in-depth business analysis to ensure the website we create for you meets your highest expectations. Your site will have all of the necessary elements to assist you in increasing your ROI and sales.

Contact Us

The content of this website is copyrighted and protected by Creative Commons 4.0.

Tags:

Vipe Team

Author Vipe Team

Our tireless team who creates high-quality WordPress-related content for you 24/7/365.

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *

We have already created hundreds of profiting websites!

We have already created hundreds of profiting websites!

Subscribe to our newsletter and get our best WordPress tips!

[mc4wp_form id="8747"]