4. If $4n+1$ and $6n+1$ are both perfect squares, then the smallest positive integer $n$ is $\qquad$
4. 20 .

Obviously, $4 n+1, 6 n+1$ are both odd square numbers.
Let $6 n+1=(2 m+1)^{2}=4 m(m+1)+1$.
Then $3 n=2 m(m+1)$.
Since $m(m+1)$ is even, $4 \mid n$.
Let $n=4 k$. Then
$4 n+1=16 k+1, 6 n+1=24 k+1$.
When $k=1,2,3,4$, $4 n+1, 6 n+1$ are not both square numbers, but when $k=5$, i.e., $n=20$, $4 n+1=81$, $6 n+1=121$ are both square numbers.
Therefore, the smallest positive integer $n$ is 20.