Zaid Alsalami, Shaykh Dr Zaid Alsalami is an Iraqi born scholar, raised in Australia. He obtained a BA from Al-Mustafa University, Qom, and an MA from the Islamic College in London. He also obtained a PhD from... Answered 4 months ago

Bismihi ta'ala

If it is 'dirt', and it is accessible, and would prevent water from getting to your out layer of skin, then it is wajib to remove, for the purpose of wudhu and ghusl. 

If the dirt is not accessible, as in it is a stain under your nail that you cannot remove, or that the dirt is not an obstacle and will not prevent water from getting to your skin, then you do not have to remove it, and your wudhu/ghusl will be valid.

And Allah knows best.