You won't believe this, but squares A and B are exactly the same shade of grey!
Demonstration
To prove it, watch this amazing video!
Incredible Shade Illusion!
About the Same Color Illusion
This amazing optical iIllusion was first published by Professor of Vision Science, Edward Adelson, in 1995.
The illusion works because the brain interprets square B as being in shadow. Also, because of the checker board pattern, the brain "knows" that square B must be light grey.
The visual system therefore compensates for the lack of light given off by square B (which is exactly the same as that for square A) by seeing square B as much lighter than it really is.
Here are the two squares in the photo with the background removed.
The extraordinary thing is that, even though we may understand this explanation, it is still almost impossible to see the two squares in the original image as being the same shade of grey.