I believe the divisor function $d(n)=\sigma_0(n)$ can be analytically continued at least for $n\in\mathbb{R}$, but I'm not sure about $n\in\mathbb{C}$.
Consider the divisor summatory function defined in formula (1) below.
$$D(x)=\sum\limits_{n=1}^x\sigma_0(n)\tag{1}$$
Now consider the analytic representation of $D_o(x)=\underset{\epsilon\to 0}{\text{lim}}\frac{D(x-\epsilon)+D(x+\epsilon)}{2}$ and it's first order derivative $D_o'(x)$ defined in formulas (2) and (3) below where the evaluation frequency $f$ is assumed to be a positive integer.
$$D_o(x)=\underset{N,f\to\infty}{\text{lim}}\left(\sum\limits_{n=1}^N \left(\frac{x}{n}-\left(\frac{1}{2}-\frac{1}{\pi}\sum\limits_{k=1}^{f\,n}\frac{\sin\left(\frac{2 \pi k x}{n}\right)}{k}\right)\right)\right),\quad x>0\tag{2}$$
$$D_o'(x)=\underset{N,f\to\infty}{\text{lim}}\left(\sum\limits_{n=1}^N\frac{1}{n}\left(1+2\sum\limits_{k=1}^{f\,n}\cos\left(\frac{2 \pi k x}{n}\right)\right)\right),\quad x>0\tag{3}$$
Finally consider the function $f'(x)$ defined in formula (4) below which is a subset of the function $D_o'(x)$ defined in formula (3) above.
$$f'(x)=\underset{N,f\to\infty}{\text{lim}}\left(2\sum\limits_{n=1}^N\frac{1}{n}\sum\limits_{k=1}^{f\,n}\cos\left(\frac{2 \pi k x}{n}\right)\right),\quad x>0\tag{4}$$
The function $f'(x)$ defined in formula (4) above evaluates exactly to $2\,f \sigma_0(n)$ when $x=n$ and $n\in\mathbb{Z}\land|n|\le N\land n\ne 0$ which leads to the following analytic formula for $\sigma_0(x)$ where the evaluation frequency $f$ may be chosen to be any positive integer.
$$\sigma_0(x)=\underset{N\to\infty}{\text{lim}}\left(\frac{1}{f}\sum\limits_{n=1}^N\frac{1}{n}\sum\limits_{k=1}^{f\,n}\cos\left(\frac{2 \pi k x}{n}\right)\right)\tag{5}$$
The following two figures illustrate formula (5) for $\sigma_0(x)$ above where Figure (1) is evaluated at $f=1$, Figure (2) is evaluated at $f=2$, and both figures are evaluated at $N=5$. The red discrete portions of the figures illustrate the value of $\sigma_0(x)$ at non-zero integer values of $x$. Note formula (5) for $\sigma_0(x)$ evaluates exactly correct when $x=n$ and $n\in\mathbb{Z}\land|n|\le N\land n\ne 0$. Also note that formula (5) evaluates to $N$ at $x=0$, and therefore the evaluation of formula (5) at $x=0$ diverges to $\infty$ as $N\to\infty$ which is consistent with the fact that zero has an infinite number of divisors. I'll also note that when evaluated at $f=2$, formula (5) for $\sigma_0(x)$ evaluates exactly to zero when evaluated at half-integer values of $x$ which is illustrated in Figure (2) below.
Figure (1): Illustration of formula (5) for $\sigma_0(x)$ evaluated at $N=5$ and $f=1$
Figure (2): Illustration of formula (5) for $\sigma_0(x)$ evaluated at $N=5$ and $f=2$
The evaluation limit $N=5$ was used in Figures (1) and (2) above to illustrate that formula (5) for $\sigma_0(x)$ evaluates exactly correct when $x=n$ and $n\in\mathbb{Z}\land|n|\le N\land n\ne 0$. I usually select a value of $N$ much greater than the largest magnitude of $x$ in the evaluation range which I think is generally desirable. Figure (3) below illustrates formula (5) for $\sigma_0(x)$ evaluated at $f=1$ and $N=100$ in the range $0<x<20.5$.
Figure (3): Illustration of formula (5) for $\sigma_0(x)$ evaluated at $f=1$ and $N=100$
The derivative $\sigma_0'(x)$ of formula (5) for $\sigma_0(x)$ above is illustrated in formula (6) below.
$$\sigma_0'(x)=\underset{N\to\infty}{\text{lim}}\left(-\frac{2\pi}{f}\sum\limits_{n=1}^N\frac{1}{n^2}\sum\limits_{k=1}^{f\,n} k \sin\left(\frac{2 \pi k x}{n}\right)\right)\tag{6}$$
Formula (6) for $\sigma_0'(x)$ above seems to be independent of the value of $f$ when evaluated at $x=1$ (see my related Math StackExchange question), so Figure (4) below just illustrates formula (6) above for $\sigma_0'(1)$ evaluated at $f=1$ as a function of $N$. Note as $N$ increases $\sigma_0'(1)$ also increases in an almost linear manner implying $\underset{N\to\infty}{\text{lim}}\sigma_0'(1)=\infty$.
Figure (4): Illustration of formula (6) for $\sigma_0'(1)$ evaluated at $f=1$ as a function of $N$
The following table illustrates the trend illustrated in Figure (4) above continues as the magnitude of $N$ increases.
$$\begin{array}{cc}
N & \sigma_0'(1) \\
10 & 6.96764 \\
100 & 96.6867 \\
1000 & 996.657 \\
10000 & 9996.65 \\
\end{array}$$