<PAGE>
                                                                     EXHIBIT 5.1

                     [Letterhead of Vinson & Elkins L.L.P.]


November 27, 2002

Lexicon Genetics Incorporated
4000 Research Forest Drive
The Woodlands, Texas 77381

Re:  Registration Statement on Form S-3 of Lexicon Genetics Incorporated

Ladies and Gentlemen:

         We have acted as counsel to Lexicon Genetics Incorporated (the
"Company"), a Delaware corporation, with respect to certain legal matters in
connection with the Company's Registration Statement on Form S-3 (the
"Registration Statement") relating to the registration by the Company under the
Securities Act of 1933, as amended (the "Securities Act"), of the offer and sale
by the Company from time to time, pursuant to Rule 415 under the Securities Act,
of up to 12,000,000 shares (the "Shares") of the Company's common stock, par
value $0.001 per share. The Company has advised us that the Shares will be
offered in amounts, at prices and on terms to be determined in light of market
conditions at the time of sale and to be set forth in supplements to the
prospectus (each, a "Prospectus Supplement") contained in the Registration
Statement to which this opinion is an exhibit.

         We have examined originals or copies, certified or otherwise identified
to our satisfaction, of the Restated Certificate of Incorporation and Restated
Bylaws of the Company, each as amended to the date hereof, the Registration
Statement, together with the exhibits thereto, and such other certificates,
documents and instruments as we considered appropriate for purposes of the
opinions hereafter expressed. As to matters of fact relevant to the opinions
expressed herein, and as to factual matters arising in connection with our
examination of corporate documents, certificates and other documents and
instruments, we have relied upon certificates and other communications of
corporate officers of the Company without further investigation as to the facts
set forth therein. In addition, we have reviewed such questions of law as we
considered appropriate.

         In connection with this opinion, we have assumed that (i) the
Registration Statement, and any amendments thereto (including any post-effective
amendments), will have become effective, (ii) a Prospectus Supplement will have
been prepared and filed with the Securities and Exchange Commission describing
the Shares offered thereby, (iii) all Shares will be issued and sold in
compliance with applicable federal and state securities laws and in the manner
stated in the Registration Statement and the



<PAGE>
Page 2
November 27, 2002

applicable Prospectus Supplement, (iv) at the time of any offering or sale of
any Shares by the Company, the Company will have such number of Shares, as set
forth in the applicable Prospectus Supplement, authorized and available for
issuance, (v) a definitive purchase, underwriting or similar agreement with
respect to any Shares offered will have been duly authorized and validly
executed and delivered by the Company and the other parties thereto and (vi)
each document submitted to us for review is accurate and complete, each such
document that is an original is authentic, each such document that is a copy
conforms to an authentic original and all signatures on each such document are
genuine.

         Based on the foregoing and subject to the qualifications and
limitations set forth below, we are of the opinion that (1) when the Board of
Directors of the Company or, to the extent permitted by Section 141(c) of the
General Corporation Law of the State of Delaware, a duly constituted and acting
committee thereof (such Board of Directors or committee being referred to herein
as the "Board"), has taken all necessary corporate action to approve the
issuance and the terms of the offering and sale of the Shares and related
matters, and (2) certificates representing the Shares have been duly executed,
countersigned, registered and delivered in accordance with the applicable
definitive purchase, underwriting or similar agreement approved by the Board
upon payment of the consideration therefor (not less than the par value of the
Shares) provided for therein, all of the Shares will be duly authorized, validly
issued, fully paid and non-assessable.

         The foregoing opinion is limited in all respects to the laws of the
State of Delaware and the federal laws of the United States of America.

         We hereby consent to the filing of this opinion as an exhibit to the
Registration Statement and to the reference to our firm under the caption "Legal
Matters" in the prospectus forming a part of the Registration Statement. By
giving such consent, we do not admit that we are within the category of persons
whose consent is required under Section 7 of the Securities Act or the rules and
regulations of the Securities and Exchange Commission issued thereunder.


                                       very truly yours,


                                       VINSON & ELKINS L.L.P.





