When to use $y = \frac{1 + x}{1 - x}$ when evaluating definite integrals
Solution 1:
\begin{align}\phi(x)=\frac{1-x}{1+x}\end{align}
1) As already pointed out $\phi\left([0;1]\right)=[0;1]$
2) the change of variable $y=\phi(x)$ preserves both:
\begin{align}&\frac{dx}{1+x^2}\\ &\frac{dx}{1+x} \end{align}
3) \begin{align}1+\phi(x)&=\frac{2}{1+x}\\ 1-\phi(x)&=\frac{2x}{1+x}\\ 1+(\phi(x))^2&=\frac{2(1+x^2)}{(1+x)^2}\\ \end{align}
Observe that $1+x,1-x,1+x^2,1-x^2,x$ are transformed into product/quotient of these same expressions. It's often nice when dealing with functions containing factors $\ln(1+x),\ln(1+x^2),\ln(x),\ln(1-x)$
NB:
this change of variable is linked to $y=\dfrac{2x}{1+x}$
PS:
Important thing: $\phi^{-1}=\phi$
PS2:
Important thing:
If $x\in [0;1]$,
\begin{align}\arctan\left(\phi(x)\right)=\frac{\pi}{4}-\arctan x\end{align}
PS3:
\begin{align} \phi(\tan x)&=\tan\left(\frac{\pi}{4}-x\right) \end{align}
$y=\phi(x)$ is the equivalent in the "algebraic side" of the trigonometric substitution $y=\dfrac{\pi}{4}-x$ for integrals $\displaystyle \int_0^{\frac{\pi}{4}}f(\tan x)dx$
ADDENDUM:
The so-called Serret integral $\displaystyle \int_0^1 \dfrac{\ln(1+x)}{1+x^2}\,dx$ wasn't first computed (at least in a text published) by Serret (see the article mentioned in Omegadot's answer)
Nowdays people copies and pastes texts from other people but often they don't check out the sources themselves.
If you search for the article of Serret (1844):
https://gallica.bnf.fr/ark:/12148/bpt6k16388p/f442n1.capture
The beginning of this article (english translation from French) says (sorry for my bad English):
"The value of this integral, given by M. Bertrand in the preceding volume of this journal, could be obtained quickly without computing any integral."
(preceding volume published in 1843)
The article of M. Bertrand about the so-called Serret integral: http://sites.mathdoc.fr/JMPA/PDF/JMPA_1843_1_8_A7_0.pdf
The method used is not easy to understand for sure. But it gives the good result.
Solution 2:
I think the substitution you mean is the so-called self-similiar substitution of $$x = \frac{1 - t}{1 + t}.$$ Notice that such a substitution is equal to its own inverse and is therefore an example of an involution.
Such a substitution works best on definite integrals when the limits of integration are between 0 and 1 and the integrand contains factors involving $x$, $1- x$, and $1 + x$ (and including terms that reduce to these through factorisation like $1 - x^2$ and so on), but naturally it is by no means limited to such integrals. Again, as with anything to do with integration, it comes down to practice.
You may find the short expository paper Finding some integrals using an interesting self-similar substitution of interest as it contains a number of interesting examples that make use of the substitution.
As a more difficult example, you may like to cut your teeth on the following: $$\int_0^1 \frac{1}{1 - x^2} \ln \left (\frac{1 + x}{2x} \right ) \, dx = \frac{\pi^2}{12}.$$