When a vacancy occurs on the US Supreme Court, it can be filled only by appointment of the president of the United States with the approval of the Senate. There's no requirement, Constitutional or otherwise, that a nominee have experience as a judge or even as a lawyer to become a Supreme Court justice, although of the 111 in US history, only 11 did not attend law school, and most of those were in the 18th and 19th centuries when a law degree wasn't required to practice law. Of the top schools in the US, Harvard Law School has seen the most graduates &emdash; 14 &emdash; go on to become a supreme court justice, while Yale Law School has sent 10 of its students to the Supreme Court and Columbia Law School boasts seven alumni who went on to become Supreme Court justices.
Despite the fact that there are no formal requirements for a nominee to become a Supreme Court justice, the vetting process is very intense, both before and after a presidential nomination. The president's staff will investigate potential nominees as thoroughly as possible in an attempt to uncover and evaluate any potentially damaging information, whether from the candidate's professional career or personal life. The president also will personally interview candidates. Once nominated, the nominee is required to complete an exhaustive questionnaire by the Senate Committee on the Judiciary, which will hold hearings on the nomination before referring it to the full Senate for the ratification vote.
Judicial experience has marked the careers of many of those who went on to become a supreme court justice, but whether such experience helps a nominee's ratification is debatable. As part of the ratification process, a nominee will testify before the Judiciary Committee in what can best be considered a very public job interview. The committee will have conducted an exhaustive investigation of the nominee's life, and any judicial activity will be explored minutely with an eye to uncovering any biases or ideology that might generate controversy.
For example, a continually controversial issue in the United States is abortion, and during the ratification process, senators try to find out how the nominee would vote on an abortion case if it reached the Supreme Court. Nominees, for their part, continually refuse to answer specifically any questions that attempt to determine how they'd vote on any particular set of circumstances, insisting that to do so would be to compromise their impartiality should such a case actually arise, thus jeopardizing the integrity of the judicial process. If the nominee had ever sat as a judge in a case involving abortion, however, the potential for one side or the other trying to use that case, and the nominee's position in it, to destroy the nomination might be sufficient grounds either to withdraw the nomination or offer it to someone else in the first place.
Thus, someone who wants to become a supreme court justice should first earn a law degree from a premier law school, and then pursue a career devoid of controversy in the hope of attracting the attention and admiration of the president without incurring the displeasure of too many senators.