<?xml version="1.0" encoding="us-ascii"?><InstanceReport xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><Version>2.2.0.25</Version><hasSegments>false</hasSegments><hasScenarios>false</hasScenarios><ReportLongName>1150 - Disclosure - Credit Agreement</ReportLongName><DisplayLabelColumn>true</DisplayLabelColumn><ShowElementNames>false</ShowElementNames><RoundingOption /><HasEmbeddedReports>false</HasEmbeddedReports><Columns><Column><Id>1</Id><IsAbstractGroupTitle>false</IsAbstractGroupTitle><LabelColumn>false</LabelColumn><CurrencyCode>USD</CurrencyCode><FootnoteIndexer /><hasSegments>false</hasSegments><hasScenarios>false</hasScenarios><MCU><KeyName>1/1/2011 - 3/31/2011
USD ($)

USD ($) / shares

</KeyName><CurrencySymbol>$</CurrencySymbol><contextRef><ContextID>D2011Q1</ContextID><EntitySchema>http://www.sec.gov/CIK</EntitySchema><EntityValue>0000875320</EntityValue><PeriodDisplayName /><PeriodType>duration</PeriodType><PeriodStartDate>2011-01-01T00:00:00</PeriodStartDate><PeriodEndDate>2011-03-31T00:00:00</PeriodEndDate><Segments /><Scenarios /></contextRef><UPS><UnitProperty><UnitID>USD</UnitID><UnitType>Standard</UnitType><StandardMeasure><MeasureSchema>http://www.xbrl.org/2003/iso4217</MeasureSchema><MeasureValue>USD</MeasureValue><MeasureNamespace>iso4217</MeasureNamespace></StandardMeasure><Scale>0</Scale></UnitProperty><UnitProperty><UnitID>USDPerShare</UnitID><UnitType>Divide</UnitType><NumeratorMeasure><MeasureSchema>http://www.xbrl.org/2003/iso4217</MeasureSchema><MeasureValue>USD</MeasureValue><MeasureNamespace>iso4217</MeasureNamespace></NumeratorMeasure><DenominatorMeasure><MeasureSchema>http://www.xbrl.org/2003/instance</MeasureSchema><MeasureValue>shares</MeasureValue><MeasureNamespace>xbrli</MeasureNamespace></DenominatorMeasure><Scale>0</Scale></UnitProperty><UnitProperty><UnitID>Pure</UnitID><UnitType>Standard</UnitType><StandardMeasure><MeasureSchema>http://www.xbrl.org/2003/instance</MeasureSchema><MeasureValue>pure</MeasureValue><MeasureNamespace>xbrli</MeasureNamespace></StandardMeasure><Scale>0</Scale></UnitProperty><UnitProperty><UnitID>Shares</UnitID><UnitType>Standard</UnitType><StandardMeasure><MeasureSchema>http://www.xbrl.org/2003/instance</MeasureSchema><MeasureValue>shares</MeasureValue><MeasureNamespace>xbrli</MeasureNamespace></StandardMeasure><Scale>0</Scale></UnitProperty></UPS><CurrencyCode>USD</CurrencyCode><OriginalCurrencyCode>USD</OriginalCurrencyCode></MCU><CurrencySymbol>$</CurrencySymbol><Labels><Label Id="1" Label="3 Months Ended" /><Label Id="2" Label="Mar. 31, 2011" /></Labels></Column></Columns><Rows><Row><Id>2</Id><IsAbstractGroupTitle>true</IsAbstractGroupTitle><Level>0</Level><ElementName>vrtx_CreditAgreementDisclosureAbstract</ElementName><ElementPrefix>vrtx</ElementPrefix><IsBaseElement>false</IsBaseElement><BalanceType>na</BalanceType><PeriodType>duration</PeriodType><ShortDefinition>No definition available.</ShortDefinition><IsReportTitle>false</IsReportTitle><IsSegmentTitle>false</IsSegmentTitle><IsSubReportEnd>false</IsSubReportEnd><IsCalendarTitle>false</IsCalendarTitle><IsTuple>false</IsTuple><IsEquityPrevioslyReportedAsRow>false</IsEquityPrevioslyReportedAsRow><IsEquityAdjustmentRow>false</IsEquityAdjustmentRow><IsBeginningBalance>false</IsBeginningBalance><IsEndingBalance>false</IsEndingBalance><IsReverseSign>false</IsReverseSign><PreferredLabelRole /><FootnoteIndexer /><Cells><Cell><Id>1</Id><IsNumeric>false</IsNumeric><IsRatio>false</IsRatio><DisplayZeroAsNone>false</DisplayZeroAsNone><NumericAmount>0</NumericAmount><RoundedNumericAmount>0</RoundedNumericAmount><NonNumbericText /><NonNumericTextHeader /><FootnoteIndexer /><CurrencyCode /><CurrencySymbol /><IsIndependantCurrency>false</IsIndependantCurrency><ShowCurrencySymbol>false</ShowCurrencySymbol><DisplayDateInUSFormat>false</DisplayDateInUSFormat><hasSegments>false</hasSegments><hasScenarios>false</hasScenarios></Cell></Cells><OriginalInstanceReportColumns /><Unit>Other</Unit><ElementDataType>xbrli:stringItemType</ElementDataType><SimpleDataType>string</SimpleDataType><ElementDefenition>No definition available.</ElementDefenition><IsTotalLabel>false</IsTotalLabel><IsEPS>false</IsEPS><Label>Credit Agreement</Label></Row><Row><Id>3</Id><IsAbstractGroupTitle>false</IsAbstractGroupTitle><Level>0</Level><ElementName>vrtx_CreditAgreementDisclosureTextBlock</ElementName><ElementPrefix>vrtx</ElementPrefix><IsBaseElement>false</IsBaseElement><BalanceType>na</BalanceType><PeriodType>duration</PeriodType><ShortDefinition>This element represent Credit Agreement.</ShortDefinition><IsReportTitle>false</IsReportTitle><IsSegmentTitle>false</IsSegmentTitle><IsSubReportEnd>false</IsSubReportEnd><IsCalendarTitle>false</IsCalendarTitle><IsTuple>false</IsTuple><IsEquityPrevioslyReportedAsRow>false</IsEquityPrevioslyReportedAsRow><IsEquityAdjustmentRow>false</IsEquityAdjustmentRow><IsBeginningBalance>false</IsBeginningBalance><IsEndingBalance>false</IsEndingBalance><IsReverseSign>false</IsReverseSign><PreferredLabelRole>terselabel</PreferredLabelRole><FootnoteIndexer /><Cells><Cell><Id>1</Id><IsNumeric>false</IsNumeric><IsRatio>false</IsRatio><DisplayZeroAsNone>false</DisplayZeroAsNone><NumericAmount>0</NumericAmount><RoundedNumericAmount>0</RoundedNumericAmount><NonNumbericText>&lt;table style="font-size:10pt; font-family:'Times New Roman',times,serif;"&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;p style="FONT-FAMILY: times"&gt;&lt;font size="2"&gt;&lt;b&gt;O. Credit Agreement&lt;/b&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p style="FONT-FAMILY: times"&gt;&lt;font size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;On January&amp;nbsp;7, 2011, the Company entered into a credit agreement with Bank of America, N.A. as administrative agent and lender. The credit agreement provides for a $100.0&amp;nbsp;million revolving credit facility that is initially unsecured. As of March&amp;nbsp;31, 2011, the Company had not borrowed any amount under the credit agreement. &lt;/font&gt;&lt;/p&gt;
&lt;p style="FONT-FAMILY: times"&gt;&lt;font size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;The Company may elect that the loans under the credit agreement bear interest at a rate per annum equal to (i)&amp;nbsp;LIBOR plus 1.50%, or (ii)&amp;nbsp;the rate of interest publicly announced from time to time by Bank of America as its prime rate. The Company may prepay the loans, in whole or in part, in minimum amounts without premium or penalty, other than customary breakage costs with respect to LIBOR borrowings. The Company may borrow, repay and reborrow under the facility until July&amp;nbsp;6, 2012, at which point the facility terminates. &lt;/font&gt;&lt;/p&gt;
&lt;p style="FONT-FAMILY: times"&gt;&lt;font size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;The agreement contains customary representations and warranties, affirmative and negative covenants and events of default, including payment defaults, defaults for breaches of representations and warranties, covenant defaults and cross defaults. The credit agreement also requires that the Company comply with certain financial covenants, including a covenant that requires the Company to maintain at least $400.0&amp;nbsp;million in cash, cash equivalents and marketable securities in domestic deposit and securities accounts, and a covenant that limits the Company's quarterly net losses. &lt;/font&gt;&lt;/p&gt;
&lt;p style="FONT-FAMILY: times"&gt;&lt;font size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;The obligations of the lender to make an initial advance under the credit agreement are subject to a number of conditions, including a satisfactory due diligence review of the Company's financial position and business. Also, if, prior to an initial borrowing under the credit agreement, the Company engages in certain investment, acquisition or disposition transactions or prepays indebtedness, such activities could restrict the Company's ability to borrow under the credit agreement.&lt;/font&gt;&lt;/p&gt;
&lt;p style="FONT-FAMILY: times"&gt;&lt;font size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;If the Company borrows under the credit agreement, the Company will become subject to certain additional negative covenants, subject to exceptions, restricting or limiting the Company's ability and the ability of the Company's subsidiaries to, among other things, grant liens, make certain investments, incur indebtedness, make certain dispositions and prepay indebtedness. &lt;/font&gt;&lt;/p&gt;
&lt;p style="FONT-FAMILY: times"&gt;&lt;font size="2"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;If the Company defaults under certain provisions of the credit agreement, including any default of a financial covenant, the loans will become secured by the Company's cash, cash equivalents and marketable securities with a margined value of $100.0&amp;nbsp;million. In addition, if an event of default occurs, the interest rate would increase and the administrative agent would be entitled to take various actions, including the acceleration of payment of amounts due under the loan. &lt;/font&gt;&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;
</NonNumbericText><NonNumericTextHeader>O. Credit Agreement
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;On January&amp;nbsp;7, 2011, the Company entered into a credit agreement with Bank of America,</NonNumericTextHeader><FootnoteIndexer /><CurrencyCode /><CurrencySymbol /><IsIndependantCurrency>false</IsIndependantCurrency><ShowCurrencySymbol>false</ShowCurrencySymbol><DisplayDateInUSFormat>false</DisplayDateInUSFormat><hasSegments>false</hasSegments><hasScenarios>false</hasScenarios></Cell></Cells><OriginalInstanceReportColumns /><Unit>Other</Unit><ElementDataType>us-types:textBlockItemType</ElementDataType><SimpleDataType>string</SimpleDataType><ElementDefenition>This element represent Credit Agreement.</ElementDefenition><ElementReferences>No authoritative reference available.</ElementReferences><IsTotalLabel>false</IsTotalLabel><IsEPS>false</IsEPS><Label>Credit Agreement</Label></Row></Rows><Footnotes /><NumberOfCols>1</NumberOfCols><NumberOfRows>2</NumberOfRows><ReportName>Credit Agreement</ReportName><MonetaryRoundingLevel>UnKnown</MonetaryRoundingLevel><SharesRoundingLevel>UnKnown</SharesRoundingLevel><PerShareRoundingLevel>UnKnown</PerShareRoundingLevel><ExchangeRateRoundingLevel>UnKnown</ExchangeRateRoundingLevel><HasCustomUnits>false</HasCustomUnits><SharesShouldBeRounded>true</SharesShouldBeRounded></InstanceReport>
