Let $G$ be an algebraic group over a field $k$, and let $BG$ be its classifying space. Let $X$ be a stack over $k$ (e.g. $X$ could be the Picard stack $Pic(S)$, for some scheme $S$). I'm trying to understand what it means to have a morphism 
$$BG \to X$$ 
of stacks. Since $BG=[pt/G]$, my guess is that a map $BG \to X$ is just an object $x \in X(k)$ together with a homomorphism of groups $G(k) \to Aut(x)$. Is this correct? This doesn't seem to take into account any of the geometric structure of $G$, so I wouldn't be surprised if this is isn't right. 


What is the right way to think of maps out of a classifying stack?



Map from a classifying space to a stack
You're almost there! The problem is that, as you've surmised, the group $\mathrm{Aut}(x)$ does not capture enough of the geometric structure of $G$. But that's easily solved:


For every $x\in X$ we can define a *sheaf* of groups $\underline{\mathrm{Aut}}(x)$ such that for every $k$-scheme $S$
$$\underline{\mathrm{Aut}}(x)(S):=\mathrm{Aut}\_{X(S)}(x\_S)\,.$$
where $x\_S$ is the image of $x$ under the functor $X(k)→X(S)$ induced by the map of schemes $S\to \mathrm{Spec}\,k$. That this is a sheaf follows from the definition of stack ("descent for morphisms"), the details might depend on your preferred way of phrasing the definition.


Then, for every sheaf of groups $G$ we can define a stack $BG$, such that for every $k$-scheme $S$ $BG(S)$ is the groupoid of $G\_S$-torsors over $S$ (this recovers the notion when $G$ is a group scheme). Note that $BG(k)$ has a distinguished object $\ast$ (corresponding to the trivial $G$-torsor over $k$) such that there's a canonical isomorphism of sheaves of groups
$$\underline{\mathrm{Aut}}(\ast)\cong G\,.$$


Then the groupoid of maps $BG\to X$ is the groupoid of pairs $(x\in X(k),\varphi:G\to \underline{\mathrm{Aut}}(x))$, where $x$ is an object of $X(k)$ and $\varphi$ is a map of sheaves of groups. The morphisms in the groupoid are the morphisms in $X(k)$ that conjugate the maps from $G$.


The map in one direction is easy: it sends $F:BG\to X$ to the pair $(F(\ast),G\cong \underline{\mathrm{Aut}}(\ast)\to \underline{\mathrm{Aut}}(F(\ast)))$.


The map in the other direction is slightly trickier: suppose I have a pair $(x,\varphi)$. Then for every $S$ I have to give a functor $BG(S)\to X(S)$. Essentially this sends a $G\_S$-torsor $T$ to $T\times\_{G\_S} x\_S$, where $G\_S$ acts on $x\_S$ via $\varphi$. Making this precise is a bit annoying and hence I shall leave it as an exercise.


Really, the easy way of conceptualizing this (and arguably proving it) is to notice that $BG$ is the stackification of the prestack $BG^{pre}$ sending $S$ to the groupoid with one objects and $G(S)$ automorphisms. Then we can compute the groupoid of maps $BG\to X$ as the groupoid of maps $BG^{pre}\to X$, and the latter is easily seen to coincide with my description above.




---


For the homotopy theorists that might be listening: yes the above could be simply summarized by saying that the functor from groups to pointed groupoids sending $G$ to $BG$ is the left adjoint to the functor sending $X$ to $\Omega X$.




---


All I described here works in an arbitrary topos: I did not use that the sheaf of groups $G$ came from a group scheme.


