The result is of course confirmed by substituting $x\mapsto\tan(x)$:
$$I = \int_0^\infty \frac{\arctan(x)}{1+x^2} \, dx = \int_0^{\frac\pi2} x \, dx = \frac{\pi^2}8$$
Or integrating by parts:
$$I = \lim_{x\to\infty} \arctan^2(x) - I \implies 2I = \left(\frac\pi2\right)^2 \implies I = \frac{\pi^2}8$$
Or splitting the integral at $x=1$ and substituting $x\mapsto\frac1x$ on the integral over $[1,\infty)$:
$$I= \int_0^1 \frac{\arctan(x) + \arctan\left(\frac1x\right)}{1 + x^2} \, dx = \frac\pi2 \int_0^1 \frac{dx}{1+x^2} = \frac{\pi^2}8$$
Or differentiating under the integral sign:
$$I(a) = \int_0^\infty \frac{\arctan(ax)}{1+x^2} \, dx \implies I'(a) = \int_0^\infty \frac x{(1+x^2)(1+a^2x^2)} \, dx = \frac{\ln(a)}{a^2-1} \\ I(0) = 0 \implies I(1) = \int_0^1 \frac{\ln(x)}{x^2-1} \, dx = \frac{\pi^2}8$$
Or getting the same integral of $\frac{\ln(x)}{x^2-1}$ by converting $\arctan(x)$ to an integral representation and computing the resulting double integral (per @Dr.WolfgangHintze's suggestion) using the same substitution as in the third method above:
$$\begin{align*} I &= \int_0^\infty \int_0^x \frac x{(1+x^2)(1+x^2y^2)} \, dy \, dx \\[1ex] &= \int_0^\infty \int_y^\infty \frac x{(1+x^2)(1+x^2y^2)} \, dx \, dy \\[1ex] &= \frac12 \int_0^\infty \frac{\ln\left(\frac{y^2+y^4}{1+y^4}\right)}{y^2-1} \, dy \\[1ex] &= \int_0^\infty \frac{\ln(y)}{y^2-1} \, dy + \frac12 \int_0^\infty \frac{\ln(1 + y^2)}{y^2-1} \, dy - \frac12 \int_0^\infty \frac{\ln(1+y^4)}{y^2-1} \, dy \\[1ex] &= (1 + 2 - 2) \int_0^1 \frac{\ln(y)}{y^2-1} \, dy = \frac{\pi^2}8 \end{align*}$$
I was wondering how, if at all possible, one might approach it with the residue theorem? I see that $z=\pm i$ are simple poles of $\frac1{1+z^2}$, but they're also the branch points of $\arctan(z)$, since
$$\arctan(z) = -\frac i2 \log\left(\frac{i-z}{i+z}\right)$$
so I don't believe the theorem can be readily applied here. The integrand is odd so I don't think there's much to infer from symmetry. Maybe there's a way to massage the integrand to get closer to something with which we can use a contour integral.