1998 Ford Explorer

Dies when Im driving it and wont start until a few hours. Will be ok for a few days and then does the same thing again.