It seems a bit strange to me why the US have so strong ties to Saudi Arabia. They wildly disagree on human rights, Saudi Arabia is member of OPEC that oil embargoed the west back in the 70s, it is known that Saudi Arabia have supported Islamic extremists - so what is it that make the US still one of its close allies, despite all those things?
I'm going to try to stay away from analysis of Saudi history and politics, since that's not really my area. However, I can speak to US reactions to Saudi policies and shifts in US foreign policy over time.
Saudi Arabia didn't become a country in its current form until the early 1930s. Prior to this, that land was four separate regions, largely ruled by the Ottoman Empire. In 1902, Ibn Saud captured Riyadh (now the capital), and spent the next 30 years conquering and uniting the remainder of what is now Saudi Arabia. Saud was able to do this partly because of his family's alliance with the Wahhabi movement. The alliance began in 1744 and linked the Sauds with strict Sunni Islam - Wahhabism continues to underpin much of Saudi policy and culture today. The efforts to overthrow the Ottomans began in the 18th century when the alliance was formed, but the Ottomans generally maintained control of the peninsula up to the capture of Riyadh in 1902.
Okay, it's now 1933 and Saudi Arabia is officially a country (as we think of it in its modern form) with diplomatic relations with the US. At the time France and Britain both had colonial interests in the region, and the US did not, making the US an attractive ally to Saud. In 1933 Saudi Arabia gave permission for Standard Oil (a US company, now Chevron) to search for oil on Saudi land, and export any oil found tax- and duty-free, in exchange for fees and royalties. This eventually became Aramco after significant oil reserves were discovered in 1938. This business arrangement meant that the US had a lot of financial and energy interest in Saudi Arabia essentially from its inception, and strongly incentivized the maintenance of good relations between the countries. (Note: the oil rights agreement was re-negotiated several times, until eventually SA took full control in 1988.) Although SA remained neutral during WWII, Roosevelt declared it eligible for lend-lease aid in 1943 because Saudi defense was of "vital interest" to the US - effectively trading security assurances for oil access. This later became a permanent US Military Training Mission in Saudi Arabia, where US forces trained Saudi troops and helped build military installations.
Post-WWII, many of the US's foreign policy decisions were driven by containing / responding to the USSR and the perceived threat of communism. Egyptian President Nasser (1956-1970) enacted policies the west perceived as threatening, such as the nationalization of the Suez Canal and pan-Arabism, and was awarded the Order of Lenin by Khrushchev in 1964. The US therefore had a vested interest in containing Soviet/communist in the region by supporting countries it perceived as pro-western and anti-Egyptian, which included Saudi Arabia. This led to the US sending fighter jets to protect SA from Egyptian bombing in 1963 (when both countries were involved in the civil war in Yemen). In addition to US concerns about Egypt, in 1979 1) the Shah of Iran, a US ally, was overthrown and replaced with an anti-western government, and 2) the USSR invaded Afghanistan. This created even more incentive for the US to support its remaining allies in the region, and notably worked with SA to fund support of anti-USSR mujaheddin in Afghanistan. During this time SA did provide arms and financial support to the future Al Qaeda, but the US did as well - it's a bit of a hindsight is 20/20 situation.
It's important to remember that OPEC and the oil embargo happened in the context of these national security concerns. Saudi Arabia cut off oil to the US after the US supported Israel in the 1973 Yom Kippur War; however, the US helped negotiate the Israel-Syria agreement over the Golan Heights in 1974, after which the US and SA expanded trade and military cooperation - including the resumption of oil sales. (The economic impact of the 1973-1974 embargo lasted well beyond 1974, but it is unlikely that SA/OPEC knew they were causing a recession with the policy at the time.)
When the Cold War ended the US no longer had to worry about the USSR exerting influence in the region, which could have weakened the US-Saudi relationship. However, the first Gulf War (1990-1991) re-cemented the relationship when SA entered the war against Iraq with the US. SA was a significant funder and staging area of the war, and US troops remained in SA after it ended to provide military support.
The ongoing presence of US troops in SA was one of the points of contention in the "Memorandum of Advice" sent to the government by the Wahhabists in 1992. Following large protests in 1994, the government ceded some control to the Wahhabists. Additionally, King Fahd had a stroke in 1995 - effectively replacing the pro-US king with his relatively anti-US son. Although oil trade continued through this time, it was definitely a weakening of relations between the two countries.
[Removed a paragraph on 9/11 here, since I forgot about the 20 year rule.]
I touched on oil and terrorism above, but want to also address your question about human rights - though the story is largely the same. It's absolutely true that the US and Saudi Arabia have differing policies regarding human rights. However, the US places an extremely high value on regional stability and maintaining such a strong ally in the Middle East, and is willing to overlook Saudi domestic policies it doesn't like as long as SA continues to be a strong economic and military partner.
To sum up, the US/Saudi relationship has had many, many ups and downs over the last century. But, both countries need things from each other that they can't get elsewhere, so the relationship is maintained. From the US perspective, there is also a "devil you know versus the devil you don't" attitude towards the Saud family - it does things the Us doesn't like, but a replacement government could be significantly worse.
(Note: I am in no way suggesting the US should value stability over human rights, just conveying the mindset that underpins a lot of US foreign policy.)
What an amazingly thorough explanation! I'm really intrigued by the depth and wide range of your answer. It really blew my mind and exceeded all my expectations, thank you!
Are there any literature you would recommend to learn more about the period from 1902 and forward?
Not to draw conclusions but there might be something to it, that a stable region is worth more than differences in policies. Oil and stability :)