Strictly speaking, the House of Lords originated in the fourteenth century when the Commons took to meeting separately. For most practical purposes, however, it is identical to the Great Council, the Norman continuation of the Anglo-Saxon Witan or Witenagemot.
In the Middle Ages the Lords Spiritual were the majority. This changed in the reign of Henry VIII, when the dissolution of the monasteries removed abbots, priors and masters of orders, leaving the bishops outnumbered by the Lords Temporal. An act of 1641 removed the bishops from the House, but it was repealed two decades later. When new bishoprics were created in the nineteenth century to cope with shifting populations, an act was passed limiting the number of Church of England bishops in the House to its existing total of 26: the Archbishops of Canterbury and York, the Bishops of London, Durham and Winchester, and the 21 other diocesan bishops in office for longest, excluding the Bishop of Sodor and Man, whose diocese is outside the United Kingdom proper. After approving the request of the General Synod of the Church of England to allow women to become bishops, Parliament in 2015 also made temporary provision for women bishops to go to the front of the queue for the next ten years.
Chapter 14 of Magna Carta speaks of "earls and greater barons" receiving individual summons to the Council. Originally the question of who counted as a "greater" baron was political, but by the seventeenth century the House had evolved the doctrine that, if someone received a summons to Parliament and he or his heir attended, this created a "barony by writ of summons" descendible to heirs. In the Wensleydale case (1876) the House confirmed that, while the Queen, as fountain of honour, could create whatever titles she wished, with whatever rules of succession she wished, they could only confer seats in the House if they satisfied certain conditions; in particular, in that case, a life peerage could not. Parliament then passed an act authorizing a limited number of "Lords of Appeal in Ordinary", commonly known as "Law Lords", with life peerages, to carry out the House's business as a court of appeal. In 1958 another act allowed unlimited life peerages, and the first women entered the House under its provisions. Female inheritors of peerages were not allowed to sit in the House until 1963.
Under the Acts of Union between England and Scotland in 1707, the Scottish peers elected for each Parliament 16 of their number. When Ireland joined the union in 1801, its peers were granted the right to elect 28 of their number, but in this case the elections were for life. After most of Ireland became independent in the 1920s, this procedure ceased to operate, and the representative peers of Ireland gradually died out, the last of them, the Earl of Kilmorey, dying in 1961. The Church of Ireland was represented by 4 bishops from 1801 to 1870, after which it was disestablished under the Gladstone government. In 1963, all Scottish peers were granted the right to sit in the House. Another reform in that act was to grant inheritors of peerages the right to disclaim them for life, thus allowing them to sit in the House of Commons instead (if elected).
Up to the early twentieth century, the Lords and Commons had comparable power, and Prime Ministers were about equally likely to sit in either House (Disraeli even moved to the Lords in the middle of his term of office, in 1876). Occasionally, the Sovereign might enforce the will of the Commons against the Lords by creating new peers, or threatening to do so. A convention evolved that the Lords would not interfere in financial matters. However, in 1909 the Lords violated this convention by rejecting the increase in death duties in Lloyd George's budget. Edward VII agreed to dissolve Parliament to allow the government to seek a fresh mandate. In the ensuing election in January 1910, the Liberals lost their large majority and came in neck and neck with the Unionists. However, the Irish Nationalists and Labour supported them and the Lords backed down. The new king, George V, then agreed to repeat the process, and a second election in December produced almost identical results. After the King agreed to create new peers if necessary, the Lords agreed to the Parliament Act 1911. This provided that, if the Commons passed a bill in three successive sessions over about two years, it could be sent for Royal Assent as an act if the Lords still refused to pass it. An exception was made for bills to extend the life of Parliament, which still required the Lords' agreement. Contrariwise, bills certified by the Speaker as "money bills" could be sent for Royal Assent if the Lords did not pass them within a month.
The 1911 act was only ever used three times (though the threat had its effects). In 1914 acts were passed under it, introduced by the same Liberal government, to disestablish the Anglican church in Wales, and to set up what would now be called a devolved Parliament for Ireland. (The implementation of the latter was deferred on the outbreak of war, and events moved on, so that it never took effect at all.) And in 1949 it was used by the Labour government to pass the Parliament Act 1949, which amended it to say that a bill only had to be passed in two successive sessions over a period of about a year. This act was itself only used once before the 1997 election, by a Conservative government to give British courts jurisdiction over war crimes committed by Nazi Germany. However, with the election of a government committed to reforming the House, the latter seems to have decided it had nothing to lose by exercising its powers to the full, and the act was used three times under the Labour government: to introduce a party list system for elections to the European Parliament, to reduce the homosexual age of consent to agree with the heterosexual one, and to ban certain forms of hunting.
The main reform made by the Labour government was the removal of most hereditary peers. It is important to note here that this included peers of first creation, not just those who had inherited their titles. A compromise negotiated with the Conservative leader in the Lords (behind his leader's back, for which he was sacked) allowed 92 to remain for the time being, a tenth of the total existing at the time. Of the 92, 2 were ex officio (the Duke of Norfolk as Earl Marshal and the Marquess of Cholmondeley as acting Lord Great Chamberlain) and the remainder elected.
In addition, the Labour government removed the judicial authority of the House (apart from its own internal affairs), transferring it to a new Supreme Court, though its initial judges were simply the existing Law Lords.
Another change they made was to the chairing of the House. Originally the King presided, and in theory the Queen could do so today. In practice, the last monarch to preside over ordinary business in the House was Queen Anne, and the last time a monarch even attended to grant Royal Assent in person was in 1856. Nowadays the Queen attends only for the formal opening ceremony. In the absence of the monarch the House is chaired by its Speaker, an office until recently normally combined with that of Lord Chancellor and a Crown appointment. The Labour government separated the two posts and allowed the House to elect its own Speaker.