It is not clear in the Bible how long Job suffered, but it was at least a period of months and may have been as long as one year according to some Jewish traditions. No matter the length of time, Job never cursed God for his suffering.
Although the Bible does not state exactly how long Job suffered, it does offer some clues. Job 2:13 mentions that Job's friends sat with him through part of it for "seven days and seven nights," so the length of time was definitely more than one week. Another scripture, Job 7:3, shows that it was possible the suffering went on for many months.