Skip to content
ihateDesmos

Integral of sin x

Updated 6 November 2026 · Checked numerically by the ihateDesmos engine
The integral of sin x
∫
sin(x)
dx =
−cos(x)+C

The integral of sin x is −cos x + C. The minus sign is there because the derivative of cos x is −sin x.

−6−4−2246−220
Open in calculator
y=sin(x)
in blue and its integral
y=−cos(x)
(with C = 0) in red.

How to integrate sin x

Method: standard integral.

  1. 1
    We know that d/dx cos x = −sin x.
  2. 2
    So d/dx (−cos x) = sin x.
  3. 3
    That makes −cos x an antiderivative of sin x.
  4. 4
    Adding the constant gives −cos x + C.

What it means

The area under one arch of the sine curve, from 0 to π, is exactly 2. Over a full cycle from 0 to 2π, the positive and negative areas cancel to 0.

The integral from 0 to π

Using the antiderivative: F(π) − F(0) = 2, which is about 2. A direct numerical integration of sin x gives 2, which agrees.

−6−5−4−3−2−1123456−2−112

Check by differentiating

The derivative of the answer should give back the original function. The last column measures that slope directly from the answer, and it matches.

Checking the integral
xsin xSlope of the answer
−5.030.9499840.949984
−3.14−0.00159265−0.00159265
−1.26−0.95209−0.95209
000
1.880.9525760.952576
3.77−0.587857−0.587857
5.03−0.949984−0.949984

Common mistakes

  • Writing cos x without the minus sign. Check by differentiating.
  • Using degrees. The formula assumes radians.

Frequently asked questions

What is the integral of sin x?
The integral of sin x is −cos x + C.
What is the integral of sin x from 0 to π?
2, which is about 2.
What is the integral of sin(ax)?
−cos(ax)/a + C.
What is the integral of sin x from 0 to π?
2. It is the area under one arch of the sine curve.

Keep going

Integrate any function

Type your own function into the integral calculator for the steps, the answer and a graph.

Open the integral calculator