Function Repository Resource:

FullWebImage

Source Notebook

Screenshot an entire webpage from top to bottom

Contributed by: Michael Sollami

ResourceFunction["FullWebImage"][url]

attempts to screenshot the entire vertical page of url.

ResourceFunction["FullWebImage"][session]

attempts to screenshot the entire vertical page of an existing session.

Details and Options

ResourceFunction["FullWebImage"] takes a single option:
Method"Firefox"web browser used for page capture ("Chrome" or "Firefox")
This operation only works with VisibleFalse in the underlying WebSessionObject.
In general, it is not always possible to do this successfully, as many webpages have dynamic and paginated scrolling behaviors.

Examples

Basic Examples (2) 

Capture the whole image of a page:

In[1]:=
ResourceFunction["FullWebImage"]["https://wolfram.com/"]
Out[1]=
Image

Screenshot a tall webpage using Firefox:

In[2]:=
url = "https://en.wikipedia.org/wiki/Star_Trek";
img = ResourceFunction["FullWebImage"][url, Method -> "Firefox"];
DynamicImage@img
Out[4]=
Image

Compare to WebImage:

In[5]:=
WebImage[url]
Out[5]=
Image

Possible Issues (2) 

Paginated websites will not work:

In[6]:=
ResourceFunction[
 "FullWebImage"]["https://www.tumblr.com/tagged/cute+puppy?sort=top"]
Out[6]=
Image

Websites with certain dynamic content may not work:

In[7]:=
ResourceFunction["FullWebImage"]["https://www.msollami.com"]
Out[7]=
Image

Publisher

Michael Sollami

Requirements

Wolfram Language 12.3 (May 2021) or above

Version History

  • 1.0.0 – 16 November 2021

Related Resources

License Information