Over the past few months, I've been preparing a guide with the tentative title, Excel for SEOs: Lessons for Aspiring Ninjas. I've embarked on this great journey because sometime during the #Mozinar back in September I decided that my Excel abilities were far too limited, especially compared to all the smarty pants that were giving great presentations and advice about SEO data analysis.
After talking with some of my colleagues I found that I wasn't alone in my feelings of Excel inadequacy. So Excel for SEOs: Lessons for Aspiring Ninjas was born as a means to help others by documenting my quest for Excel Ninj-ocity. The full document will be released sometime in January, but here is a selection that I hope provides some value alone.
Update: The guide has been released! Give it a read!
While having a working knowledge of the functions described below can help with a multitude of SEO tasks, the specific tasks that we'll be completing in the following include:
- Isolating the root domains from a group of full URLs
- Stripping the descriptive portion of a URL out of the full URL
-----SNIP-----
Lesson 2: More Functions - Text Manipulation
The functions on which we'll be focusing in this lesson are useful for dealing with text manipulation. As we'll see from the examples, there are quite a few scenarios wherein the SEO has to manipulate a text string. Some of the formulas we'll talk about are pretty simple to grasp individually, but can get a bit confusing when used together. We'll touch on:
- LEN
- SEARCH/FIND
- LEFT, RIGHT, MID
LEN
Microsoft Excel Definition: Returns the number of characters in a text string.
Syntax: LEN(text)
I doubt this requires much explanation. LEN alone is fairly useless. Sorry LEN.
SEARCH/FIND
Microsoft Excel Definition:
SEARCH - Returns the number of the character at which a specific character or text string is first found, reading left to right (not case-sensitive).
FIND - Returns the starting position of one text string within another text string. FIND is case-sensitive.
Syntax: SEARCH(find_text,within_text,start_num) and FIND(find_text,within_text,start_num)
There are two differences between SEARCH and FIND. SEARCH is not case-sensitive, FIND is. SEARCH allows the use of wildcards, FIND does not. Under most circumstances, SEARCH is all you need, but it helps to know that FIND is always there if you've got to deal with pesky capital letters in URLs or something similar. Another reason to choose FIND is if you're dealing with URLs that contain parameters. Without properly escaping question marks, they will act as wild cards, which may cause some frustration.
In our example below, we've pulled out the character number at which the "/blog/" string begins. Much like LEN, this function is a bit silly on its own, but can be combined with some of our other functions to do some cool things.
This is good but its not very pretty, let's use IFERROR to get rid of those #VALUE!s
The IFERROR syntax: IFERROR(value,value_if_error)
So much better!
LEFT, RIGHT, MID
Microsoft Excel Definition:
LEFT: Returns the specific number of characters from the start of a text string.
RIGHT: Returns the specific number of characters from the end of a text string.
MID: Returns the characters from the middle of a text string, given a starting position and length.
Syntax:
LEFT(text,num_chars)
RIGHT(text,num_chars)
MID(text,start_num,num_chars)
Both LEFT and RIGHT return the characters from a given position in a text string starting from either side of a string. MID is great for extracting a portion of a text string. I've lumped the three together because they are often used in conjunction with each other (along with a few of the earlier functions). Let's dive into an example:
Bringing it all together - Example 1
Let's say we've been given a list of URLs, and we want to extract just the domain.
This formula will do the job. Let's break down this nested formula, and see how it pulls just the domain out of our URL. Starting from the middle we see SEARCH, which uses the syntax:
SEARCH(find_text,within_text,start_num)
In plain terms, this formula finds the first instance of "/" in the cell to the left, starting at the 8th character from the beginning, which is done to start passed the double slash in https://. As we see below, the result for the first row of data is 22.
The same formula with the inner function calculated
Now we are left with a simple LEFT formula. Remember, the syntax for LEFT is LEFT(text,num_chars).
In plain terms: Give us the first 22 characters starting from the beginning. The number of characters differs depending on URL, but adjusts accordingly when applied to the rest of the table. We now have a nice listing of just root domains.
Our list of root domains. The formula reflects the change to a table format from the simple range used previously.
Example 2
Let’s use SEARCH (with wildcards) and MID together to extract a portion of a URL:
Let's assume we want to pull the descriptive piece out of each of these URLs for reporting purposes
We’ll definitely be making use of MID, as the text we want is in the MIDdle of our string. We’ll need to determine how many characters make up the "-tXXX.html" bit at the end of each URL. Since the length of this portion of the URL varies, but the format doesn’t (that is, "-t" + "numbers" + ".html"), we can use wildcards to find this character count.
Again, the syntaxes for these 2 functions:
MID(text,start_num,num_chars)
SEARCH(find_text,within_text,start_num)
Let's break down the formula for the first URL in our list.
Cell A2: https://www.example.com/lamp-maintenance-t83.html
=MID(A2,SEARCH("/",A2,8),SEARCH("-t*.html",A2)-SEARCH("/",A2,8)) =MID(A2,23, SEARCH("-t*.html",A2)-23)
We've calculated the first instance of a "/" after the 8th character. This gives us our start_num values. We're also using the * wildcard to help us get the character count of the right-most chunk of text.
=MID(A2,23,SEARCH("-t*.html",A2)-23) =MID(A2,23,40-23)
We can easily calculate the number of characters for our MID once we know where our non-descriptive characters begin.
=MID(A2,23,17) /lamp-maintenance
Hooray!
Example 2.5
Let's make a small adjustment to our original URL to demonstrate how we can use LEN in this formula.
Cell A2: https://www.example.com/t1521-lamp-maintenance.html
=MID(A2,SEARCH("-",A2)+1,LEN(A4)-SEARCH("-",A2)-5) =MID(A2,29+1,50-29-5) lamp-maintenance
The additional +1 and -5 are necessary to make minor adjustments to the final outcome. Without them, our final result would have been "-lamp-maintenance.html".
-----SNIP-----
Thus concludes the sample lesson on manipulating text strings in Excel. I hope you've found it useful, and not too confusing!
If you have any questions, ask away in the comments and follow me (@MikeCP) and @Distilled on Twitter for more info on the full release of Excel for SEOs: Lessons for Aspiring Ninjas. There's much more where this came from, including bits on pivot tables, VLOOKUP, Index/Match, OFFSET, and more!
It's great to see others using Excel for SEO. I've blogged about the topic a few times in the past year.
https://www.blindfiveyearold.com/seo-excel-functions
https://www.blindfiveyearold.com/seo-pivot-tables
Great examples of using SEARCH, FIND, LEFT, RIGHT and MID, all Functions I didn't cover myself. However, I think the IFERROR is the hidden gem of the bunch. If you have data OCD like I do, it's a necessity.
Hahaha Data OCD. I love it. Brilliant way to describe that need to get rid of those #VALUE, #N/A, and #DIV/0's. :)
Thanks for linking to these posts AJ. I'll definitely be checking them out as I've been slacking in my Excel skills.
No problem. We're in this together and we can all use some extra tips on how to use Excel to make our SEO lives better.
Brilliant idea for a series, Mike. Looking forward to a lot more of these, as I think Excel skills are a big part of what separates the data jockeys and those who have to feel their way by intuition through the SEO process.
Plus - I want to know what functions and analyses we should be putting in our web app to make this easy for everyone :-)
Looks like the post of the year rundown should have waited a week - this gets my vote, and a big thumbs up!
Wow. Numbers, Numbers, Numbers... I wish I were more of a numbers person. Do you think it's possible to be an effective SEO if you're more of a people person? I mean, tools like this are awesome, but if my mind doesn't work this way, am I doomed?
LOL Malechi. Being a data head certainly lends itself to doing the grunt work of SEO, but being a people person lends itself to getting and retaining clients. And since adding/retaining clients is the lifeblood of business you're in a good spot.
I love this question!
You're not doomed, not in the slightest. Everyone has their natural inclinations, but by working on what doesn't come naturally, you'll develop a more well-rounded skillset. Sure, a "numbers" person might always grasp a new Excel concept a bit quicker than a "people" person, but a "people" person might have an easier time understanding the needs of a client. The more valuable of the two people is the one that works to improve overall.
I don't consider myself a numbers person, and in fact, most of the content in my Excel For SEOs document would've scared the crap out of me a few months ago :).
I think we need to write a post at some point, we use a variety of forumlas and functions - most of it quite basic, but not all well known on Custom Crawls - suddenly they go from a long list of almost meaningless data to a "traffic" light system ... Easy when you know how :D
Ciao Mike,
as Rand wrote above, I think that posts like this one are maybe the most needed. Infact, it is ok to talk and discuss about futures and theories (I am referring to me first), but when it comes to the daily life of an SEO, Excel (as other tools) is our love/hatred companion; and everybody here know how much a specific guide of Excel for SEOs is needed.
At least, it is very much needed for me, especially to have one source that explains it all (or almost) as a reference.
Great stuff Mike. Cool to see this stuff getting out into the wild. Maybe we should release the internal training videos. Or maybe not :)
Will, don't be cruel ;)... don't tickle us :)
Hah hah. You should definitley release the training videos, because after all, it's Christmas week :)
That would be a nice idea.
Great introductory article to the complex world of Excel. It's definitely one of those topics where the more I learn, the more I realize I don't know.
Two other functions I find extremely useful for this sort of work are SUBSTITUTE() and CONCATENATE(), although I usually use the shorthand version of the latter by employing ampersands. Combined with the ones you've already mentioned, all sorts of manipulations are possible.
Much <3 for CONCATENATE(). Seriously.
CONCATENATE is covered in Lesson 1 ;)
I will look out for the full release too. My excel skills used to be reasonable but they leave a lot to be desired these days. It would really save us time i think as well as the marked improvement in our spreadsheets.
Hi Mike,
Thanks for the tips... Only thing, is that you might want to adjust search to allow for 9 characters, as it will then allow for https://
:)
Cheers,
Jake
Slightly more applicable today Jake!
This is a great supplement for Ann Smarty's posts on SEO for excel such as the Grand Collection of Tips at Search Engine Land, Check out this link aswell: https://www.searchenginejournal.com/using-excel-for-seo-the-grand-collection-of-tips/23077/
There are a few neat pointers in your tutorial above - especially the application of stripping the centre heart part out of a url or string. Can we see more please????
Keep these coming! I can't wait! I'd love to increase my knowledge in this area and SAVE SO MUCH TIME!!!! ;)
Great link to Ann's article Turkey. Thumbs up.
Great article and I look forward to seeing more on this topic. word
My current job function is Competitive Intelligence. We use a combinations of 7 tools to gather information which is then stored in 3 different databases.
I use Excel to organize this mess. By using Excel “Connections” I am able to connect to the remote databases, centralize, analyze, and report on reams of the data we collect. I also have used the Visual Basic for Applications (VBA) ability of Excel to have it produce custom information graphics from our data. Video example: https://bit.ly/c78Ne1
Excel is one of those tools that never seems to stop amazing me.
This is awesome - bookmarked. I can't think of the number of time's I've needed to manipulate text in Excel and given up because I didn't know how.
As an SEO I utilise VLOOKUP a lot for a variety of functions (e.g. to compare referring keywords from search engines one week vs. the previous) so looking forward to the next installment of this series to see if there's any additional tidbits I can pick up. Thanks for posting.
This technique is very useful especially to people who are managing their blogs and blog links. This makes their work easier especially to those who are maintaining dating sites. They will no longer have a hard time managing their links because of this Excel technique.
Nevermind... :). Good post.
If you don't want to mess with formulas you can use a slider (much more limited however):
Select cells, go to Data, Text to Columns, select "Fixed With", (next), and drag a line that divides the first 8 characters from the rest. Click Finish.https://www.mrexcel.com/forum/showthread.php?t=780
Ive been using excel and I just discovered this lately and it was great! I love it. Now I can organize more especially on gadgets infos and so on.
What do you mean by you can organize gadgets? Anyway, this excel technique is truly useful! Thanks.
I will absolutely be adding this to my repertoire. It is these type of tools that can literally save you hours of work. Thanks for the great presentation
Great post, looking forward to seeing the full guide. Another function I find very useful is when you have multiple sheets or files is =vlookup(...) Has saved me a lot of time
Thank you, Mike, great article. Very helpful. I need to improve my excel skills.
I will absolutely be adding this to my repertoire. It is these type of tools that can literally save you hours of work. Thanks for the great presentation
Excellent post Mike. LEN isn't completely useless alone though - it can be used to count characters when writing PPC ads. Great work!
Lots of useful tips in here! I use Scrapebox for many of these functions currently but I could definitely use some freshening up on my Excel skills.
I would love to get this when it is released but I have a problem. For me I feel like this could be a step or 2 step above where my excel Ninja skill level is at.
What you would recommend as pre-requiste for taking your course?
Suggestions on sites, books, ebooks, webinars would be greatly appreciated!
Fortunately, this is actually the 2nd lesson in my doc, so lesson 1 might be a good place to start. Stay tuned for the full release in January. Outside of my work Mr. Excel (https://www.mrexcel.com/) is a good place to do some reading.
Thank You Thank You MikeCp!
Thanks for the brief introduction into Excel. I'm definitely looking forward to the full release in January cos I know my Excel skills leave a lot to be desired on a good day.
No need to say that it is exceptional idea of use. I will try to work with that, Now I was using ms-word for counting the charectors of meta tags.
Great to see excel being used to its potential, as an apps spec this is bread and butter stuff.
Cheers
Nice post Mike. When you get the full blown article going, will you be publishing it here or elsewhere?
I agree with all above that said they can't get enough Excel tips. Excel is like the ocean. Vast, full of richness yet also capable of drowning you :)
Unsure where the full release will be housed, but I'll almost certainly be posting here again when the time comes. Maybe another excerpt. Glad you liked it :)
Unique and innovative post..thanks..also big thanks to make sense how Microsoft excel calling the funtions..
Looking forward for the full release in January. In the meantime I will hopefully find enought time to practise your shown functions during the holidays.
This was great stuff. I've tried a couple of these options myself using data exported from Google SERPs or yahoo link portfolios. We also record the sites we attempt to get links on, but sometimes I want to know how much activity i get on a true root domain or to avoid it in our next activity (i.e. identify the # of occurrences of a root domain in a spreadsheet).
In other words, I want to count/flag the same root domain in both "yoursite.com" and "subdomain.yoursite.com". I found it hard to write a formula that pulled out the same root domain in both options and still ignored urls that had www or not (sometimes the same link has www and sometimes not). i created a manual option using a macro and delimited text to columns, but prefer to cut that step out. When building thousands of links a month, these kinds of steps can make a confusing, broad link building landscape less confusing and reduce time.
Any blog posts about this out there anyone knows about?
Good idea. Thanks
Jorge Hane
www.jorgehane.com.ar
Great stuff for us Excel Ninjas wannabes!
thanks!