I do not recommend doing this type of verification.
An HTTP request must contain, in a very brief way, only the address to be obtained, the way of obtaining it (ie GET) and optionally parameters for the page. Any data in addition is courtesy of the browser. So much so that it is trivial to make a client go through any browser.
The intent of anonymous mode is to pass as little data as possible to the page you want to get. If you decide to get the data that the browser wants to hide, you have entered a game of cat and mouse. This is exactly why some solutions proposed in two previous answers (already deleted and only visible to those with more than 10,000 points) have already worked one day, but they do not work anymore.
If you can get something that works today, tomorrow may not work anymore. And when it stops working, it's going to be unannounced, and you'll have to chase after another gambiarra.
Finally, this afternoon's solution is to use the File System API, which from time to time behaves differently in incognito mode. When this technique starts to be used a lot (it will not take long), the Chromium people will find a way to solve this. Until then, you can risk your luck. You can find the documentation on how to use it in MDN, but even there you already start your study with this warning (my emphases):
This feature is non-standard and is not on a standard track. Do not use it on production sites facing the Web: it will not work for every user. There may also be large incompatibilities between implementations and the behavior may change in the future .
This feature is not standard and is not on the trail of the patterns to implement. Do not use this on production sites and web-accessible: this will not work for all users. There may be large incompatibilities between implementations and behavior may change in the future . p>