DaisyI said:
Your pot looks pretty shallow so I don't think its a problem. Ferocactus don't have taproots, instead their roots spread out very near the surface in all directions. In habitat, several feet. I do think Subtropix is right about two different soils in your pot not melding but this is the wrong time to repot if you are anywhere in the Northern hemisphere. Did you repot it? How long ago? Did you shake any of the old soil off before you replanted?
You may be able to work some of the soil out from under the plant without disturbing the roots so the bottom of the cactus is more at soil level. If you do decide to repot, wait a couple months. In the meantime, water by soaking the entire pot up to its rim to try to hydrate the soil in the rootball. Given a chance, the cactus roots will grow out of the rootball - your plant looks pretty happy so it may have already happened. But, if you can pick the plant up without pulling it up, it has not so re-settle it deeper into the pot. Don't water for a week to 10 days after you do anything to the roots.