



                                       July 11, 1996

Pegasystems Inc.
101 Main Street
Cambridge, MA  02142

Gentlemen:

      This opinion is delivered to you in connection with the
registration statement (the "Registration Statement") on Form S-1
of Pegasystems Inc. (the "Company") filed on May 15, 1996 with
the Securities and Exchange Commission by the Company under the
Securities Act of 1933, as amended, for registration under said
Act of 3,910,000 shares of the common stock, $.01 par value (the
"Common Stock"), of the Company.

      We are familiar with the Articles of Organization of the
Company, as amended, the corporate minute book and the by-laws of
the Company, as amended, and the Registration Statement.  We have
also made such further investigation as we have deemed necessary
for the purposes of this opinion.

      Based upon and subject to the foregoing, we are of the
opinion that the shares of Common Stock to be sold by the Company
pursuant to the prospectus contained in the Registration
Statement (the "Prospectus") have been validly authorized for
issuance and, when issued against receipt of the purchase price
described in the Prospectus, will be legally issued, fully paid
and nonassessable.

      We understand that this opinion is to be used in connection
with the Registration Statement.  We consent to the filing of
this opinion as an exhibit to the Registration Statement and the
reference to our firm in the Prospectus under the caption "Legal
Matters."

                                       Very truly yours,


                                       CHOATE, HALL & STEWART


