<PAGE>
                                                                     EXHIBIT 4.8
 
                              AMENDMENT NO. 2 TO
                           STOCK PURCHASE AGREEMENT
                           ------------------------


     This Amendment No. 2 to Stock Purchase Agreement (this "Amendment") is
entered into as of this 21/st/ day of August, 1998, among Focal Communications
Corporation, a Delaware corporation (the "Company") and the stockholders listed
on the signature page hereof (the "Stockholders").  Capitalized terms not
otherwise defined in this Agreement are used herein with the meanings assigned
to such terms in the Stock Purchase Agreement, dated November 27, 1996, by and
among the Company and the parties thereto, as amended by Amendment No. 1 to
Stock Purchase Agreement dated January 23, 1998 (the "Stock Purchase
Agreement").

     WHEREAS, the Company and the Stockholders wish to amend the provisions of
the Stock Purchase Agreement as provided in paragraph 1 of this Amendment; and

     WHEREAS, the Stockholders collectively own all of the Institutional
Investor Stock and at least a majority of the Executive Stock;

     NOW, THEREFORE, for good and valuable consideration, the receipt and
sufficiency of which is hereby acknowledged, the parties to this Amendment
hereby agree as follows:

     1.   Amendment to Stock Purchase Agreement.  Pursuant to Section 9D of the
          -------------------------------------                                
Stock  Purchase Agreement, Section 4 of the Stock Purchase Agreement is hereby
amended by adding the following subsection at the end of such section:

     "4K  Termination.  The provisions of Sections 4C, 4D, 4E, 4G, 4H, 4I, 4J
          -----------
and 9G of this Agreement shall terminate at the closing of a Public Offering."

     2.   Counterparts.  This Amendment may be executed in multiple
counterparts, each of which shall be an original and all of which taken together
shall constitute one and the same agreement.

     3.   Descriptive Headings.  The descriptive headings of this Amendment are
          --------------------                                                 
inserted for convenience only and do not constitute a part of this Amendment.
<PAGE>
 
     IN WITNESS WHEREOF, the parties hereto have executed this Amendment as of
the date first above written.


_________________________     MADISON DEARBORN CAPITAL
Brian F. Addy                 PARTNERS, L.P.
                              By:  Madison Dearborn Partners, L.P., its General
                                   Partner
                              By:  Madison Dearborn Partners, Inc., its General 
                                   Partner

_________________________     By:_________________________________________
John R. Barnicle                   Its:___________________________________


                              
_________________________     FRONTENAC VI, L.P.
Joseph Beatty                 By:  Frontenac Company, its General Partner

                              By:_________________________________________
                                   Its:___________________________________


_________________________     BATTERY VENTURES III, L.P.
Robert C. Taylor, Jr.         By:  Battery Partners III, L.P., its General
                                   Partner

                               By:________________________________________
                                    Its:__________________________________


                              FOCAL COMMUNICATIONS CORPORATION

                              By:_________________________________________
                                   Its:___________________________________

                                       2