How do you formally define dimension of a set without using metrics, charts, an atlas, or a vector space structure?
$\mathbb{R}$ and $\mathbb{R}^2$ are equinumerous, but $\dim \mathbb{R} = 1 \neq 2 = \dim \mathbb{R}^2$.
Is there no way to formally talk about this without using span or basis vectors?
Really, I'm looking for the minimal structure imposed on sets to talk about dimensionality of a set.
It doesn't make sense to talk about the dimension of a mere set - the only structural property a set has is its cardinality. And this is very little structure indeed (after all, $\vert\mathbb{R}\vert=\vert\mathbb{R}^2\vert$).
The weakest common type of structure which suffices to have some nontrivial notion(s) of dimension is a topology. Vaguely speaking, from a geometric perspective a mere topology grants much less information (and permits many more pathologies) than a metric, and from an algebraic perspective there is in general no algebraic structure fitting nicely on an arbitrary topological space. So topological spaces are pretty minimal, in the structure department, and consequently topological notions of dimension seem quite relevant.
Expanding on Alessandro Codenotti's comment above, here are two purely topological notions of dimension. (The standard text on topological dimensions is Engelking's Dimension theory.)
Inductive dimension. There are actually two of these, the large and small inductive definitions; I'll define the small one ($ind$) here since I think it's simpler. The idea is that a sign that something is $(n+1)$-dimensional is that its open sets often have $n$-dimensional boundary. This suggests the following (unsurprisingly, inductive) definition:
$ind(X)=-1$ iff $X=\emptyset$.
Having defined when $ind(X)=n$, we say $ind(X)=n+1$ iff for each point $a\in X$ and open $U\ni a$ there is an open $V\ni a$ with $cl(V)\subseteq U$ and $ind(\partial V)\le n$ (where $\partial S$ is the boundary of $S$).
Covering dimension. This notion arises when we think about how dimension interacts with "overlaps" created when we try to efficiently cover the space by small open sets. E.g. in two dimensions, if we tile $\mathbb{R}^2$ with a bunch of open balls we can arrange that at no point do four or more of the balls overlap, but we can't avoid three overlapping balls. The formal definition is a bit of a mouthful: it says that $dim_{cov}(X)=n+1$ iff for every open cover $\mathcal{C}$ of $X$ there is an open cover $\mathcal{D}$ of $X$ such that
each element of $\mathcal{D}$ is a subset of some (perhaps more than one) element of $\mathcal{C}$, and
each $x\in X$ is in at most $n+1$ many distinct elements of $\mathcal{D}$.
Each definition correctly computes the dimension of $\mathbb{R}^k$. For general spaces they can behave rather differently however, and of course there are spaces which do not get assigned a finite dimension in either sense.