Available-for-Sale Securities and Fair Value Measurements | 3. Available-for-Sale Securities and Fair Value Measurements The following table sets forth our financial instruments that were measured at fair value on a recurring basis by level within the fair value hierarchy (in thousands): December 31, 2018 Level 1 Level 2 Level 3 Total Cash and cash equivalents: Cash and money market funds $ 107,511 $ — $ — $ 107,511 Total cash and cash equivalents $ 107,511 $ — $ — $ 107,511 Investments: Agency securities — 17,352 — 17,352 Corporate securities — 54,474 — 54,474 Commercial paper — 5,965 — 5,965 US government securities — 118,630 — 118,630 Total investments $ — $ 196,421 $ — $ 196,421 December 31, 2017 Level 1 Level 2 Level 3 Total Cash and cash equivalents: Cash and money market funds $ 39,072 $ — $ — $ 39,072 Corporate securities — 999 — 999 Commercial paper — 33,416 — 33,416 Total cash and cash equivalents $ 39,072 $ 34,415 $ — $ 73,487 Investments: Agency securities — 12,718 — 12,718 Corporate securities — 28,345 — 28,345 Commercial paper — 21,432 — 21,432 US government securities — 46,448 — 46,448 Total investments $ — $ 108,943 $ — $ 108,943 Our valuation techniques used to measure the fair value of money market funds were derived from quoted prices in active markets for identical assets. The valuation techniques used to measure the fair value of investments, all of which have counterparties with high credit ratings, were valued based on quoted market prices or model-driven valuations using significant inputs derived from or corroborated by observable market data. Investments are carried at fair value. During the years ended December 31, 2018 and 2017, there were no transfers between Level 1 and Level 2 of the fair value hierarchy. Available-for-sale investments are carried at fair value and are included in the tables above. The aggregate market value, cost basis, and gross unrealized gains and losses of available-for-sale investments by security type, classified in cash equivalents and investments, as of December 31, 2018 and December 31, 2017 are as are as follows (in thousands): December 31, 2018 Amortized Cost Gross unrealized gains Gross unrealized losses Total fair value Agency securities $ 17,361 $ - $ (9 ) $ 17,352 Corporate securities 54,536 — (62 ) 54,474 Commercial paper 5,965 — — 5,965 US government securities 118,667 14 (51 ) 118,630 Total available-for-sale investments $ 196,529 $ 14 $ (122 ) $ 196,421 December 31, 2017 Amortized Cost Gross unrealized gains Gross unrealized losses Total fair value Agency securities $ 12,729 $ - $ (11 ) $ 12,718 Corporate securities 29,369 1 (26 ) 29,344 Commercial paper 54,848 — — 54,848 US government securities 46,520 — (72 ) 46,448 Total available-for-sale investments $ 143,466 $ 1 $ (109 ) $ 143,358 At December 31, 2018, all of the available-for-sale securities have contractual maturities within one year. We periodically review our available-for-sale investments for other-than-temporary impairment loss. We consider factors such as the duration, severity and the reason for the decline in value, the potential recovery period and our intent to sell. For debt securities, we also consider whether (i) it is more likely than not that we will be required to sell the debt securities before recovery of their amortized cost basis, and (ii) the amortized cost basis cannot be recovered as a result of credit losses. During the years ended December 31, 2018, 2017, and 2016 we did not recognize any other-than-temporary impairment losses. All marketable securities with unrealized losses have been in a loss position for less than twelve months. 3. Available-for-Sale Securities and Fair Value Measurements The following table sets forth our financial instruments that were measured at fair value on a recurring basis by level within the fair value hierarchy (in thousands): December 31, 2018 Level 1 Level 2 Level 3 Total Cash and cash equivalents: Cash and money market funds $ 107,511 $ — $ — $ 107,511 Total cash and cash equivalents $ 107,511 $ — $ — $ 107,511 Investments: Agency securities — 17,352 — 17,352 Corporate securities — 54,474 — 54,474 Commercial paper — 5,965 — 5,965 US government securities — 118,630 — 118,630 Total investments $ — $ 196,421 $ — $ 196,421 December 31, 2017 Level 1 Level 2 Level 3 Total Cash and cash equivalents: Cash and money market funds $ 39,072 $ — $ — $ 39,072 Corporate securities — 999 — 999 Commercial paper — 33,416 — 33,416 Total cash and cash equivalents $ 39,072 $ 34,415 $ — $ 73,487 Investments: Agency securities — 12,718 — 12,718 Corporate securities — 28,345 — 28,345 Commercial paper — 21,432 — 21,432 US government securities — 46,448 — 46,448 Total investments $ — $ 108,943 $ — $ 108,943 Our valuation techniques used to measure the fair value of money market funds were derived from quoted prices in active markets for identical assets. The valuation techniques used to measure the fair value of investments, all of which have counterparties with high credit ratings, were valued based on quoted market prices or model-driven valuations using significant inputs derived from or corroborated by observable market data. Investments are carried at fair value. During the years ended December 31, 2018 and 2017, there were no transfers between Level 1 and Level 2 of the fair value hierarchy. Available-for-sale investments are carried at fair value and are included in the tables above. The aggregate market value, cost basis, and gross unrealized gains and losses of available-for-sale investments by security type, classified in cash equivalents and investments, as of December 31, 2018 and December 31, 2017 are as are as follows (in thousands): December 31, 2018 Amortized Cost Gross unrealized gains Gross unrealized losses Total fair value Agency securities $ 17,361 $ - $ (9 ) $ 17,352 Corporate securities 54,536 — (62 ) 54,474 Commercial paper 5,965 — — 5,965 US government securities 118,667 14 (51 ) 118,630 Total available-for-sale investments $ 196,529 $ 14 $ (122 ) $ 196,421 December 31, 2017 Amortized Cost Gross unrealized gains Gross unrealized losses Total fair value Agency securities $ 12,729 $ - $ (11 ) $ 12,718 Corporate securities 29,369 1 (26 ) 29,344 Commercial paper 54,848 — — 54,848 US government securities 46,520 — (72 ) 46,448 Total available-for-sale investments $ 143,466 $ 1 $ (109 ) $ 143,358 At December 31, 2018, all of the available-for-sale securities have contractual maturities within one year. We periodically review our available-for-sale investments for other-than-temporary impairment loss. We consider factors such as the duration, severity and the reason for the decline in value, the potential recovery period and our intent to sell. For debt securities, we also consider whether (i) it is more likely than not that we will be required to sell the debt securities before recovery of their amortized cost basis, and (ii) the amortized cost basis cannot be recovered as a result of credit losses. During the years ended December 31, 2018, 2017, and 2016 we did not recognize any other-than-temporary impairment losses. All marketable securities with unrealized losses have been in a loss position for less than twelve months. |