Update 06 Dec 2023: Microsoft has made a number of drastic changes to their rewards program as of late, and one such change involved the removal of MSN Shopping Games. As such, this article is no longer of any relevance whatsoever.
Warning: Microsoft has updated the shopping game several times to deter the use of exploits, and as of 21 Jul 2023, the use of bots, cheats, macro, or other automated method to obtain Rewards points is now a bannable offense.
As such, this blog post will no longer be kept updated with the latest exploits.
If you want to take the risk anyway, the creator of these scripts has continued to update their code, and their latest changes can be found via this Reddit post or via the creator’s Pastebin account.
Table of contents.
Microsoft has a fairly interesting Rewards program that allows us to redeem gift cards, Xbox games, gaming accessories, and even consoles using Rewards points.
One way to earn points is to play the MSN Shopping Game.
The shopping game can be found by navigating to the Shopping tab on either msn.com or bing.com, and then scrolling down to the middle of the page.
Author’s note: There is some speculation that the shopping game is not available in certain countries. I can confirm that it is available in Australia.
Players are required to guess which of the products listed has the lowest price, with each correct guess granting 10 points with a limit of 10 guesses per day.
The game is also fairly lenient in the fact that you can click through each of the products listed and view the actual product page to compare their prices. The bing shopping tab is recommended for this because you can use CMD/CTRL + left click on the “See more” button to open product links, instead of two clicks on msn.
Unfortunately, the price of these products may change at any time. The product might also go out of stock and become unavailable. This game is a buggy mess and is really bad at keeping track of changes in availability and pricing, which makes it almost impossible to choose correctly and get the full 100 points each day.
So Reddit users created a bookmarklet that reduces the number of products listed in the game to one per round, making it impossible to select an incorrect answer.
The following code has been modified based on a number of suggestions in the Reddit post comments, including some style adjustments to move the shopping game to the top of the page for easier access.
javascript: (() => {
let msnShoppingGamePane = document.querySelector("shopping-page-base")
?.shadowRoot.querySelector("shopping-homepage")
?.shadowRoot.querySelector("msft-feed-layout")
?.shadowRoot.querySelector("msn-shopping-game-pane");
if(msnShoppingGamePane){
msnShoppingGamePane.style.setProperty("grid-area", "slot1");
msnShoppingGamePane.cardsPerGame = 1;
msnShoppingGamePane.resetGame();
msnShoppingGamePane.setAttribute("gamestate", "active");
}else alert("Unable to locate the shopping game!");
})()
See my previous blog post to learn how you can make use of this bookmarklet by copying and pasting the code into your browser bookmarks or favourites.
Side note: For those who want to try and read and understand the above code, the “?.” operator is called optional chaining in JavaScript.
Update 25 Jun 2023.
Microsoft has made some changes to the Shopping Games about 4 days ago and the code above no longer works. Fortunately, the creator of the above bookmarklet followed through and updated their code as well.
javascript: (() => {
let msnShoppingGamePane = document.querySelector("shopping-page-base")
?.shadowRoot.querySelector("shopping-homepage")
?.shadowRoot.querySelector("msft-feed-layout")
?.shadowRoot.querySelector("msn-shopping-game-pane");
if(msnShoppingGamePane != null){
msnShoppingGamePane.gameSettings.newGameCountdown = 0;
msnShoppingGamePane.style.gridArea = "slot2";
msnShoppingGamePane.getGameResult = function(e) {
if (e === msnShoppingGamePane.selectedCardIndex){
msnShoppingGamePane.nextRoundShoppingEntities = [msnShoppingGamePane.nextRoundShoppingEntities[0]];
localStorage.removeItem("gamesPerDay");
msnShoppingGamePane.dailyLimitReached = false;
if(msnShoppingGamePane.leaderboardRecord)
msnShoppingGamePane.leaderboardRecord.dailyGuessingGamesPlayed = 0;
return e === -1 ? msnShoppingGamePane.resetGame() : msnShoppingGamePane.gameState === "win" ? "win" : "lose";
}
};
msnShoppingGamePane.getGameResult(-1);
}else alert("Unable to locate the shopping game!");
})()
If you have trouble with getting the full 100 Rewards points, the creator has even provided a more complete version of the script that may help remedy the situation.
Update 28 Jun 2023.
Microsoft has updated the Shopping Game yet again to enforce a 6-second timeout between rounds. Fortunately, the creator of the bookmarklet script has kept up with the changes.
javascript: (async function() {
var e = document.querySelector("shopping-page-base")
?.shadowRoot.querySelector("shopping-homepage")
?.shadowRoot.querySelector("msft-feed-layout")
?.shadowRoot.querySelector("msn-shopping-game-pane");
if (null != e) {
e.style.gridArea = "slot2", window.scrollTo(0, 0);
var t = [];
t = t.concat(
await e.fetchGameDataFunc(),
await e.fetchGameDataFunc(),
await e.fetchGameDataFunc()),
e.fetchGameDataFunc = async function(e) {
return [t[Math.floor(Math.random() * t.length)]]
},
window.startCountdownOG || (window.startCountdownOG = e.startCountdown, e.startCountdown = function() {
window.startCountdownOG.call(e), setTimeout((() => {
if (!window.gameCounterElem) {
window.gameCounter = -1;
var t = document.createElement("div");
t.className = "view-leaderboard stats-game-counter",
t.style = "right: unset; left: 25px; font-size: 13px;",
e.gameContainerRef.getElementsByClassName("game-panel-container")[0].appendChild(t),
window.gameCounterElem = t
}
window.gameCounter++,
window.gameCounterElem.textContent = `Game: ${window.gameCounter}`
}), 1e3 * e.gameSettings.newGameCountdown + 1e3)
}),
e.getGameResult = function(t) {
if (t === e.selectedCardIndex) return localStorage.removeItem("gamesPerDay"),
e.dailyLimitReached = !1,
e.leaderboardRecord && (e.leaderboardRecord.dailyGuessingGamesPlayed = 0),
"win" === e.gameState ? "win" : "lose"
},
e.gameSettings.newGameCountdown = 0,
e.getGameResult(-1),
e.gameState = "win",
e.startCountdown(),
e.startCountdown(),
setTimeout((() => {
for (var t = 0; t <= 1e4; t++) clearInterval(t);
e.gameSettings.newGameCountdown = 6
}), 2200)
} else alert("Unable to locate the shopping game!\nRefresh the page and try again.");
})();
Update 09 Jul 2023.
In an unsurprising twist, Microsoft has updated the shopping games (yet again!) about 2 days ago, and the above code has ceased to work as intended. It’s a constant back-and-forth, and I applaud the creator of these scripts for keeping up with Microsoft’s changes thus far.
javascript: (function() {
var z, e = document.querySelector("shopping-page-base")
?.shadowRoot.querySelector("shopping-homepage")
?.shadowRoot.querySelector("msft-feed-layout")
?.shadowRoot.querySelector("msn-shopping-game-pane");
function t() {
e.displayedShoppingEntities.length > 1 && (e.displayedShoppingEntities = [e.displayedShoppingEntities[0]]),
localStorage.removeItem("gamesPerDay"),
e.dailyLimitReached = !1,
e.leaderboardRecord && (e.leaderboardRecord.dailyGuessingGamesPlayed = 0),
e.gameState = "idle" == e.gameState ? "active" : e.gameState
}
window.scOg || (window.scOg = e.startCountdown),
e.startCountdown = function(t) {
setTimeout((() => {
if (!window.gameCounterElem) {
window.gameCounter = 0;
var t = document.createElement("div");
t.className = "view-leaderboard stats-game-counter",
t.style = "right:unset;left:25px;font-size:13px;",
e.gameContainerRef.getElementsByClassName("game-panel-container")[0].appendChild(t),
window.gameCounterElem = t
}
window.gameCounter++,
window.gameCounterElem.textContent = `Game: ${window.gameCounter}`
}),
1 == t ? t : 1e3 * e.gameSettings.newGameCountdown + 1150),
1 != t && window.scOg.call(e)
}, e.gSCS = function(t) {
return e.isGameFinished ? "--price-color:#00AE56;--price-color-dark:#00AE56" : ""
}, e.getGameResult = async function(a) {
if (e.isGameFinished) return e.gameState = "win",
t(),
e.selectedCardIndex != e.c_ai && e.selectedCardIndex > -1 && (e.gameContainerRef.querySelector("fluent-card").parentElement.style = "border:4px solid rgb(0, 174, 86)",
e.selectedCardIndex = -1,
e.confettiAnimate.play(),
await async function() {
return await fetch("https://assets.msn.com/service/news/feed/segments/shopping?ocid=shopping-shophp-Peregrine&apikey=Xr2pbC1j5NMUwFF5YHTlhDDkcftEafmPoVP3pfA5eZ&timeOut=10000&cm=" + MeControl.Config.mkt.toLowerCase() + "&scn=MSNRPSAuth&$select=rewards|reportactivity|guessinggame&$filter=~5000&t=" + Date.now().toString(), {
cache: "no-store",
headers: {
Authorization: `Bearer ${z}`
}
})
}()), "win"
};
var a = localStorage.getItem("1s-tokens");
a ? (e.style.gridArea = "slot2",
window.scrollTo(0, 0),
z = JSON.parse(a).accessToken,
setInterval(t, 100),
e.startCountdown(1)) : alert("Failed'");
})();
Update 21 Jul 2023.
Microsoft has updated the Shopping Game yet again, and it appears that the use of bots, cheats, macro, or other automated method to obtain Microsoft Rewards points is now a bannable offense.
As such, this blog post will no longer be kept updated with the latest exploits.
If you want to take the risk anyway, the creator of these scripts has continued to update their code, and their latest changes can be found via this Reddit post or via the creator’s Pastebin account.
And lastly, a word of caution: it is always best to review any code you find online before copying and running it on your device.
Update 11 Aug 2023.
I tried tinkering with some of the earlier bookmarklet code in the hopes of making the Bing shopping game easier to access without having to scroll all the way down to the middle of the page.
And yes, I prefer playing the shopping game on Bing rather than on MSN because with Bing, you can hold the “CTRL” button on your keyboard and click on the “See more” button in the shopping game and quickly bring up its pricing in a new tab.
Unfortunately, Microsoft has made some changes (yet again…) to their code, and the entire main section of the Bing shopping page is now enclosed within an iframe. This makes it almost impossible to interact with using bookmarklets.
The funny thing is, I have devised a simple bookmarklet that sidesteps this problem altogether – by reloading the Bing shopping page using the source of that iframe.
javascript: (() => {
let iframe = document.getElementById("msn-shop-hub-iframe");
if(iframe) window.location.href = iframe.src;
else alert("Unable to locate the iframe!");
})()
As a side note, if you are accessing the shopping game via MSN, ignore the above bookmarklet because their shopping page is not encapsulated in an iframe.
Once the Bing shopping page has reloaded, we can use the following bookmarklet to bring the shopping game up to the top of the page.
javascript: (() => {
let e = document.querySelector("shopping-page-base")
?.shadowRoot.querySelector("shopping-homepage")
?.shadowRoot.querySelector("msft-feed-layout")
?.shadowRoot.querySelector("msn-shopping-game-pane");
if(e){
e.style.gridArea = "slot2", window.scrollTo(0, 0);
let style = document.createElement('style');
style.innerHTML = '.wavy { animation-duration: 0s !important; }';
e.shadowRoot.appendChild(style);
}else alert("Unable to locate the shopping game!");
})()
I have also added some CSS styles to disable the bounce animation that moves the shopping game cards up and down, making the buttons rather difficult to click.
You would still have to play the shopping game yourself though. Personally, I am no longer willing to risk cheating and getting banned from Microsoft Rewards.
Update 29 Aug 2023.
Microsoft seems to have changed the name of a HTML tag, so here’s my updated code to bring the shopping game to the top of the page.
javascript: (() => {
let e = document.querySelector("shopping-page-base")
?.shadowRoot.querySelector("shopping-homepage")
?.shadowRoot.querySelector("cs-feed-layout")
?.shadowRoot.querySelector("msn-shopping-game-pane");
if(e){
e.style.gridArea = "slot2", window.scrollTo(0, 0);
let style = document.createElement('style');
style.innerHTML = '.wavy { animation-duration: 0s !important; }';
e.shadowRoot.appendChild(style);
}else alert("Unable to locate the shopping game!");
})()
Final update 06 Dec 2023.
Microsoft has made a number of drastic changes to their rewards program as of late, and one such change involved the silent removal of MSN Shopping Games.
As such, this article is no longer of any relevance whatsoever, and is only kept on this website for the sake of posterity.