This is a matter of significant scholarly discussion. Nabi (shallallahu alaihi wa sallam) stated clearly that no woman should travel without a mahram, and this is the basis for the Hanafi and Hanbali position that a mahram is an absolute condition for a woman's obligation of Haji. If a woman has no mahram willing and able to travel with her, Haji is not wajib upon her according to these schools.
Sheikh Ibn Baz and Sheikh Ibn Uthaymeen both held the position that a mahram is required for a woman traveling for Haji, and that without a mahram, the obligation of Haji does not apply to her. If she dies without having performed Haji due to the absence of a mahram, she is not sinful. They considered the mahram to be part of the conditions of istitaa'ah (ability) for women.
However, the Shafi'i and Maliki schools hold a different position. They permit a woman to travel for wajib Haji with a group of trustworthy women, even without a mahram, provided that safety is ensured. Imam al-Nawawi reported the Shafi'i position that a mahram is not a condition for the obligation of Haji if the woman can travel safely with trustworthy companions. The Saudi Ministry of Haji now permits women aged 45 and above to perform Haji without a mahram if traveling with an organized group.