Categories: General

Facebook’s hidden battle against ad-blockers

Image copyright
AFP

The methods Facebook uses to thwart ad-blocking technology have been criticised by web developers.

The social network injects dozens of lines of code in every page to make it harder for ad blockers to detect and hide sponsored posts.

But that makes the website less efficient and stops software such as screen readers used by visually impaired users from working properly.

The BBC has contacted Facebook for comment.

In order to block advertising, developers look for patterns in a website’s code that can be consistently identified and hidden.

It would be easy for a plug-in to spot the word “sponsored” or to find a container labelled “ad” inside the webpage code, so companies, including Facebook, use coding tricks to obfuscate their ads.

The tricks Facebook uses to fool ad-blocking plug-ins include:

  • breaking up the word “sponsored” into small chunks only one or two letters long
  • inserting extra letters, as in “SpSonSsoSredS”, hidden to the viewer
  • adding the word to all regular posts on the news feed, even ones that are not ads, and then using another piece of code to hide it on the non-ads

Facebook provides some controls for users to influence the ads they see.

“Although you can’t opt out of seeing ads entirely, you can influence the types of ads you see by giving us feedback or hiding ads and advertisers that you don’t want to see,” it says in its help centre.

Developers working on the uBlock Origin browser plug-in have been documenting their counter-measures on coding site Github.

Image copyright
facebook

Image caption

Facebook uses all this code to show the word “sponsored”

In one case, they worked at blocking ad containers labelled “feed_subtitle” and “feed-subtitle”.

“That solves it quite neatly,” one said. But two days later, Facebook had changed its code again.

“These guys act quick. Now the div [container] is named ‘feed_sub_title_ 128; 1402960186614717; 0; 2216051248638936; 1542673577: -7185000746684546330: 5:0:47233’,” a coder said.

One, posting as filbo, pointed out that the sponsored text was different depending on your language settings, so ad-blocking efforts should not focus on the word “sponsored”.

“If a workable UI-language-neutral expression can be written, that’s better,” they wrote.

Another, posting as okiehsch, suggested development would never stop.

“I doubt very much that Facebook will stop trying to push their ads, so this issue will never be ‘fixed’,” they wrote.



Source by [author_name]

Share
Published by

Recent Posts

TEST: Living Like a RockStar: Get in Front of YOUR Money (Part 4)

TEST... If it is alright with you, would it not be better to make it…

2 years ago

TEST: Living Like a RockStar: Zero Fear Selling & Having it YOUR Way (Part 5)

TEST... Would it be okay with you if selling was just easy? Would you be…

2 years ago

TEST: Where To Get No Cost Royalty Free Music For Your Videos

TEST... Adding music to your videos can help to increase engagement, sales and more. We…

2 years ago

TEST: Today We Talk About Needs in Ben’s Ride Along video

TEST... This is very rarely discussed. And it is one of the most powerful things…

2 years ago

TEST: Sell These Videos For $500 or More Each?

TEST... In this video, I show you (Watch Over My Shoulder Style) how you can…

2 years ago

TEST: The “Shell Shock Habit” – RockStar Entrepreneur

TEST... More times than not, you may find that the thing holding you back has…

2 years ago