MacMost Q&A Forum • View All Forum QuestionsAsk a Question

How Do I Copy Only the Text Of a Hyperlink?

For example, I have purchased an item on ebay and recveived an HTML email with the USPS Tracking number as a hyperlink. If I click the link it opens ebay’s page which takes two more clicks to get the actual tracking info. I want to copy the tracking number and paste it into the USPS page and track that way but if I use the traditional method the entire hyperlink is pasted into the USPS tracking number field.

Comments: 2 Responses to “How Do I Copy Only the Text Of a Hyperlink?”

    2 years ago

    The answer depends on how the email is coded. When you view an email you are looking at the result of HTML code that contains things like hyperlinks, styling, images and more. So there is no one-answer-fits-all solution for grabbing the tracking code. But there are some things you can try.

    If you see the actual tracking number then you may be able to select it and copy the number, not the link. It sounds like the number is a hyperlink, so clicking anywhere in the number will probably just activate the link. But if you click before the number, and then drag across the number, then you should be able to select it and Command+c to copy it. One thing that may help is to use Command+c before you release the mouse/trackpad as doing so may activate the link too. You can also try selecting right after the code and dragging to the left to select it that works better.

    In some cases you end up with an extra character at the front or back of the selected text. But it is easy to trim those off when you paste them to get what you want.

    You may also be able to Control+click the link and select the option to copy the link instead of activating it. But it sounds like it is a link to Ebay, so that may not help. Still, if this link seems to contain the tracking code, you can always paste it into TextEdit or something and then select just the tracking code and do a search for that — Google should recognize these codes and take you right there.

    Whether you use these techniques or just follow the Ebay links, you can always bookmark the resulting tracking page and use that from then on, until your item arrives. That’s what I do.

    2 years ago

    Thank you! Indeed the number is the hyperlink and copying dead space before or after does work. Seems like with all the HTML based emails today a key+click sequence that only copies the label would be very useful. Love your site and emails! Thank you!!!

Comments Closed.